Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- online_students = 0
- onsite_students = 0
- for i in range(3):
- education_form = input()
- student_count = int(input())
- if education_form == "online":
- online_students += student_count
- else:
- onsite_students += student_count
- if onsite_students > 600 :
- online_students += onsite_students - 600
- onsite_students = 600
- print(f"Online students: {online_students}\n"
- f"Onsite students: {onsite_students}\n"
- f"Total students: {online_students + onsite_students}")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement