- Home
- Studylists
Output Questions for Class 10 ICSE Computer Applications
Output Questions for Class 10 ICSE Computer Applications
Java Operators
If m = 5 and n = 2, predict the output values of m and n:
(a) m -= n;
(b) n = m + m/n;
View Answer198 Likes
Java Operators
What will be the output of the variable 'a'?
int a=0,b=10,c=40; a = --b + c++ + b; System.out.println(" a = " + a);
View Answer206 Likes
Java Operators
Rewrite the following program segment using if-else statements instead of the ternary operator:
String grade = (marks>=90)?"A": (marks>=80)? "B": "C";
View Answer115 Likes
Java Operators
Rewrite the following program segment using if-else statements instead of the ternary operator:
net = (salary > 10000) ? salary - (8.33/100)*salary : salary - (5/100)*salary
View Answer62 Likes
Java Operators
Predict the output of the below Java program snippet:
int a = 14, b = 4; boolean x = (a > b) ? true : false;
View Answer34 Likes
Java Operators
If int y =10 then find int z = (++y * (y++ + 5));
View Answer87 Likes
Java Operators
Predict the output of the below Java program snippet:
int c = (3<4)? 3*4:3+4;
View Answer68 Likes
Java Operators
Rewrite the following using ternary operator:
if(a > b) { if (a > c) g = a; else g = c; } else if (b > c) g = b; else g = c;
View Answer197 Likes
Java Operators
Rewrite the following using ternary operator:
if (x % 2 == 0) System.out.println("Even"); else System.out.println("Odd");
View Answer101 Likes
Java Operators
Predict the output of the below Java program snippet:
int a = 18; int b = 12; boolean t = (a > 20 && b < 15)? true : false;
View Answer38 Likes