Counting a’s (2)

Write a program that reads a sequence of characters and prints the
number of letters ‘a’ in the sequence before the first period.

Input

Input consists of a sequence of characters with at least one period.

Output

Print the number of times that ‘a’ appears in the sequence before the
first period.

Observation

The expected solution for the
exercise problem://problemsjutge.org:problems/p1/roura/comptar-as.pbm is
also a correct solution for this exercise.

Problem information

Author: Unknown
Translator: Carlos Molina

Generation: 2026-01-25T11:32:39.343Z

© Jutge.org, 2006–2026.
https://jutge.org
