Hello, just wondering how to count words up to a point (for example, a period)?

For example, given the string:

That was a fun movie. I want to watch it again. We should sometime.

What code would you need to count the words in each individual sentence (that is, 5, 6 then 3 using the above example string)?

Thank you, I've been looking for a solution to this problem but it's got the better of me