It's totally weird how we can have dreams that predict the future

I've had several totally random dreams before and similiar events ended up happening. The first weird one I had was about my ex boyfriend. In my dream, I saw him in his car in a parking lot and he was holding a little child that looked to be no more than 2 years old. One week later, I found out from a friend, that my ex boyfriend had gotten his new girlfriend pregnant. That was also the first time I had dreamed about my ex boyfriend in ages. I also had other random dreams about my closest friends, and then the same (or similar) events happened in real life. My best friend told me to notify her whenever I have a dream about her, even if it's at 4:00am and about something totally pointless or crazy lol.