Question: 1. (2 pt) The following statement should determine whether x is not greater than 100. What is wrong with it? if(! x > 100) 2.
1. (2 pt) The following statement should determine whether x is not greater than 100. What is wrong with it? if(! x > 100) 2. (2 pt) Assume that partNumber references a String object. The following if statement should perform a case- insensitive comparison. What is wrong with it? if (part Number -- "BQ7894") 3. (2 pt) The following statement should determine whether count is outside the range of o through 100. What is wrong with it? if (count 100) cout 4. (6 pt) Consider the following method. public static void mystery(int 1, int )) { while (i != 0 && j !- 0)) { 1 = 1/3: j - (1 - 1) % 3; System.out.print(1+""+ 1 + " "); System.out.println(1); For each call below, indicate what output is produced. mystery(10,3) mystery(7,5) and mystery(15,4) 5. (4 pt) Convert the following program (including do-while loop) into an equivalent program that includes a while loop. 1
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
