Write a Java program for a school for assigning students to exam halls. Your program should ask students to enter their student number via keyboard, then tells them in which exam hall they should do their exam. In this school, student numbers have a 6-digit format and range between 212001 to 222999. Your program should assign students to the exam halls as: ▪ If the last two digits of a student number is between 00 to 33, The student is assigned to Hall-x ▪ If the last two digits of a student number is between 34 to 66, The student is assigned to Hall-y. ▪ If the last two digits of a student number is between 67 to 99, The student is assigned to Hall-z. An error message should be printed in the console if the entered student number is not in the range. Note that you may use nested if statements in your program struc
Write a Java
▪ If the last two digits of a student number is between 00 to 33, The student is assigned to Hall-x
▪ If the last two digits of a student number is between 34 to 66, The student is assigned to Hall-y.
▪ If the last two digits of a student number is between 67 to 99, The student is assigned to Hall-z.
An error message should be printed in the console if the entered student number is not in the range.
Note that you may use nested if statements in your program structure. But none of the branching conditions should use logical conjunction or logical disjunction expression.
Step by step
Solved in 4 steps with 4 images
Hello, great work.
A quick question - there is no boolean expression used anywhere in the script right ? If yes then please provide a boolean expression exempt code. If its not used then its fine.