CSC 175 - Intermediate Programming

Dr. R. M. Siegfried

Assignment #4 - How many seats are left in a classroom?

Due Wednesday, January 31, 2024

You work for the Registrar's office and have to know if there are any seats available in a classroom and if so how many?

Write a program that reads two (2) inputs: the number of students in a class and the number of total seats in the classroom.

If there are still available seats in the classroom, print the number of available seats. If there aren't any seats available, print a message to that effect.

Please make sure that your program checks for bad data, i.e., that neither the number of students nor the number of seats is negative.

[Back to the Assignment Index]