favorite We need a little bit of your help to keep things running, click on this banner to learn more

Programming Principles 1. Week 6. October 7 - 13. PART 2

Number of sentences

Find the number of sentences in the text. Consider a sentence ending with one of the characters "." (point), "!" (exclamation point) or "?" (question mark), but there are no character sets like "...", "!!!" и "?!" in the text.


One line of text that consists of Latin characters, punctuation marks and spaces.


Print the number of sentences in the text.

Time limit 1 second
Memory limit 128 MiB
Input example #1
Hello, world!
Output example #1
Author Matviychuk Sergiy Volodymyrovych
Source "ABC programming"