We had sex after a few months?

So I was seeing a guy earlier this year and then it ended. We stayed friends and have spoken since the break. Yesterday we met up again and one thing lead to another now I’m confused as to why this happened.
We had sex after a few months?
Post Opinion