Q5Single correct3 Marks1 Sep 2024
A system categorizes people based on their age as follows:
Which of the following snippets computes and prints the category after accepting the age as input? Assume that the input entered by the user will be an integer and will lie only in the range .
Snippet-1
age = int(input())
```
age = int(input())
if age < 13:
category = 'Child'
elif age < 20:
category = 'Teenager'
elif age < 60:
category = 'Adult'
else:
category = 'Senior Citizen'
print(category)
```
Snippet-2
age = int(input())
```
age = int(input())
if age < 13:
category = 'Child'
if age < 20:
category = 'Teenager'
if age < 60:
category = 'Adult'
else:
category = 'Senior Citizen'
print(category)
```