Page 236 - ComputerScience_Class_11
P. 236
Unsolved Questions
A. Tick ( ) the correct option.
1. Which of the following methods finds the highest value among x and y in Java?
a. Math.max(x,y) b. Math.high(x,y)
c. Max.Math(x,y) d. High.Math(x,y)
2. The code given below is an example of:
for(i=10; i>=1; i++)
{
System.out.println(i);
}
a. Delay loop b. Empty loop
c. Infinite loop d. None of these
3. What will be the output of Math.pow(3,3)?
a. 3 b. 27.0
c. 27 d. 9.0
4. Which of the following functions finds the logarithm of a value provided in the argument?
a. Math.sin() b. Math.tan()
c. Math.logarithm() d. Math.log()
5. Which of the following functions returns the value in the argument to its nearest integer?
a. Math.round() b. Math.abs()
c. Math.pow() d. None of these
6. Identify the package in which math functions of java are present.
a. util b. applet
c. lang d. None of these
7. Which of the following is/are jump statements?
a. continue b. break
c. return d. All of these
8. Which of the following is called entry-controlled loop?
a. for b. do-while
c. continue d. break
B. Fill in the blanks.
1. If ………………… is not present in switch case, then the situation is known as fall through.
2. If the statements of a programming language executes from first to last, then it follows ………………… approach.
3. When an 'if statement' is placed inside another 'if statement', then it is known as ………………… .
4. ………………… is a multiple-branch selection statement.
5. The flow of control is ………………… i.e. depending on the user's choice.
6. ………………… is required to send the control to the next iteration of the loop.
7. ………………… function is used to find the square root of a number.
8. ………………… function finds the smallest integer value greater than the number that is provided in the argument.
9. Math.rint() function returns the nearest value of the fractional number in ………………… .
10. Math.floor(-20.4) will return ………………… .
234 Touchpad Computer Science (Ver. 3.0)-XI

