Neuer Kurs! Jeder Programmierer sollte generative KI lernen!
- 7

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? 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.

6th Dec 2020, 5:16 AM
Otaku Gamer
5 Antworten
+ 9
Read the task carefully. We have to take input for no of passengers first then we have to compute the remaining passengers through Hint:you can use "%" operator to find the remaining passengers. How you will find the empty seats now?🚀
6th Dec 2020, 5:48 AM
Simba
+ 7
Your attempt is missing in the question description
6th Dec 2020, 5:44 AM
Arsenic
+ 5
Otaku Gamer "you are making a program for a bus service" where is the program/code?
6th Dec 2020, 6:04 AM
Piyush
0
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.
2nd Jan 2021, 12:33 PM