+ 1

Can you someone help me to solve this?

You are making a program for a bus service. A bus can transport 50 passengers at once. Given the number of passengers waiting in the bus station as input, you need to calculate and output how many empty seats the last bus will have. Sample Input: 126 Sample Output: 24 Explanation: The first bus will transport 50 passengers, leaving 126-50=76 in the station. The next one will leave 26 in the station, thus, the last bus will take all of the 26 passengers, having 50-26=24 seats left empty.

13th Jul 2022, 2:51 PM
Daysiree Maranan
Daysiree Maranan - avatar
4 Answers
+ 4
What help you need here? For code related, try first yourself and post your attempt if unsolved...
13th Jul 2022, 3:12 PM
Jayakrishna šŸ‡®šŸ‡³
+ 2
https://code.sololearn.com/ctRTaL5PRfK6/?ref=app Hi! I solved the task, if something is not clear, ask me!
13th Jul 2022, 4:15 PM
ŠšŠ°Š²ŃƒŠ½ šŸ‰
ŠšŠ°Š²ŃƒŠ½ šŸ‰ - avatar
0
I think I know that challenge and a little hint for that you can better calculate it with: Input%50 Further help and tips with Code attempt. šŸ˜‰
13th Jul 2022, 3:38 PM
Felix Alcor
Felix Alcor - avatar