Exam 3: Decision Structures
Exam 1: Introduction to Computers and Java42 Questions
Exam 2: Java Fundamentals53 Questions
Exam 3: Decision Structures52 Questions
Exam 4: Loops and Files48 Questions
Exam 5: Methods50 Questions
Exam 6: A First Look at Classes49 Questions
Exam 7: A First Look at Gui Applications49 Questions
Exam 8: Arrays and the Arraylist Class52 Questions
Exam 9: A Second Look at Classes and Objects40 Questions
Exam 10: Text Processing and More About Wrapper Classes49 Questions
Exam 11: Inheritance49 Questions
Exam 12: Exceptions and Advanced File Io46 Questions
Exam 13: Advanced Gui Applications46 Questions
Exam 14: Applets and More39 Questions
Exam 15: Recursion34 Questions
Exam 16: Sorting, Searching, and Algorithm Analysis46 Questions
Exam 17: Generics50 Questions
Exam 18: Collections50 Questions
Exam 19: Array-Based Lists20 Questions
Exam 20: Linked Lists36 Questions
Exam 21: Stacks and Queues36 Questions
Exam 22: Binary Trees, Avl Trees, and Priority Queues45 Questions
Select questions type
What would be the value of discountRate after the following statements are executed? double discountRate = 0.0;
Int purchase = 1250;
If (purchase > 1000)
DiscountRate = .05;
If (purchase > 750)
DiscountRate = .03;
If (purchase > 500)
DiscountRate = .01;
Else
DiscountRate = 0;
(Multiple Choice)
4.8/5
(36)
Which of the following will format 12.78 to display as 012.8?
(Multiple Choice)
4.8/5
(39)
In a switch statement,if two different values for the CaseExpression would result in the same code being executed,you must have two copies of the code,one after each CaseExpression.
(True/False)
4.8/5
(33)
What is the value of ans after the following code has been executed? int x = 35;
Int y = 20,ans = 80;
If (x < y);
Ans += y;
(Multiple Choice)
4.8/5
(32)
In an if/else statement,if the boolean expression is false,
(Multiple Choice)
4.7/5
(37)
What will be the value of ans after the following code has been executed? int x = 90,y = 55,ans = 10;
If ( x == y);
Ans *= 2;
(Multiple Choice)
4.9/5
(34)
Which of the following is the correct boolean expression to test for: int x being a value less than or equal to 500 or greater than 650,and int y not equal to 1000?
(Multiple Choice)
4.9/5
(34)
If str1 and str2 are both Strings,which of the following will correctly test to determine whether str1 is less than str2? (1)(str1 < str2)
(2)(str1.equals(str2)< 0)
(3)(str1.compareTo(str2)< 0)
(Multiple Choice)
4.8/5
(43)
Which of the following will format .1278 to display as 12.8%?
(Multiple Choice)
4.9/5
(37)
Which of the following is the correct boolean expression to test for: int x being a value between,but not including,500 and 650,or int y not equal to 1000?
(Multiple Choice)
4.8/5
(44)
An important style rule you should adopt for writing if statements is to write the conditionally executed statement on the line after the if statement.
(True/False)
4.8/5
(35)
The _________ statement is used to make simple decisions in Java.
(Multiple Choice)
4.8/5
(35)
Showing 41 - 52 of 52
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)