407194: GYM102697 165 In The Zone
Memory Limit:256 MB
Time Limit:1 S
Judge Style:Text Compare
Creator:
Submit:0
Solved:0
Description
165. In The Zonetime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard output
While doing your gym assignments in quarantine, your gym teacher makes you record your heart rate after your workouts, and separates them into five "zones". These zones of fitness are sorted dependant on your maximum heart rate (MHR), which is determined by taking your age, and subtracting it from 220.
The zones are separated thusly:
Zone 5: 90 - 100 percent of MHR
Zone 4: 80 - 89 percent of MHR
Zone 3 : 70 - 79 percent of MHR
Zone 2 : 60 - 69 percent of MHR
Zone 1 : <60 percent of MHR
InputGiven the first line as the age of the student, the second line will contain an integer $$$n$$$ which denotes the amount of test cases to follow.
OutputPrint the appropriate fitness zone for each given test case.
ExamplesInput16 3 165 152 86Output
Zone 4 Zone 3 Zone 1Input
25 5 103 166 182 153 123Output
Zone 1 Zone 4 Zone 5 Zone 3 Zone 2