#C1272. Count Eligible Friends
Count Eligible Friends
Count Eligible Friends
You are given the ages of n friends. A friend is eligible to participate in an activity if their age is in the range \(18 \leq age \leq 25\). Your task is to count the number of eligible friends.
Input Format: The first line contains an integer n which is the number of friends. The second line contains n space-separated integers representing the ages of the friends.
Output Format: Output a single integer representing the number of eligible friends.
Example:
Input: 5 17 21 19 26 23</p>Output: 3
inputFormat
The first line contains one integer n
(the number of friends).
The second line contains n
space-separated integers denoting the ages of the friends.
outputFormat
Output a single integer - the count of friends whose age is between 18 and 25 (inclusive).
## sample5
17 21 19 26 23
3