Question
The program should allow the user to enter information about each step in the process and the program should determine whether the bill has become a law. If a bill does not become a law then the user should be informed where in the process the bill failed to move to the next step. The steps involving the House of Representatives and the Senate should include the number of people voting for and against a bill to allow the program to determine whether the bill has passed each legislative body.
Note: There are 435 representatives in the House and 100 senators in the Senate.
Solution Preview
This material may consist of step-by-step explanations on how to solve a problem or examples of proper writing, including the use of citations, references, bibliographies, and formatting. This material is made available for the sole purpose of studying and learning - misuse is strictly forbidden.
import java.util.Scanner;public class BillProcession {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
final int representatives = 435;
final int senators = 100;
Scanner scanner = new Scanner(System.in);
System.out.println("Please enter the suitable number");
System.out.println("Note: There are 435 representatives "
+ "in the House and 100 senators in the Senat");
System.out.println("");
int rSupporter = getNumber(representatives,
"Number of representatives who suports this bill: ", scanner);
int sSupporter = getNumber(representatives,
"Number of senators who suports this bill: ", scanner);
System.out.println("");...