Advertisements
Chapters
1.2: Elementary Concept of Objects and Classes
1.3: Values and Data Types
▶ 1.4: Operators in Java
1.5: Introduction to Java
1.5: Input in Java
1.6: Mathematical Library Methods
1.7: Conditional Statements in Java
1.8: Iterative Constructs in Java
1.9: Nested Loop
2: Library Classes
3: Arrays (Single Dimensional and Double Dimensional)
4: String Handling
5: User - Defined Methods
6: Class as the Basis of all Computation (Objects and Classes)
7: Constructors
8: Encapsulation and Inheritance
![Avichal solutions for Computer Applications [English] Class 10 ICSE chapter 1.4 - Operators in Java Avichal solutions for Computer Applications [English] Class 10 ICSE chapter 1.4 - Operators in Java - Shaalaa.com](/images/computer-applications-english-class-10-icse_6:1e1eb1b47d2b4696b609e5cd9260118f.jpg)
Advertisements
Solutions for Chapter 1.4: Operators in Java
Below listed, you can find solutions for Chapter 1.4 of CISCE Avichal for Computer Applications [English] Class 10 ICSE.
Avichal solutions for Computer Applications [English] Class 10 ICSE 1.4 Operators in Java Review Insight [Page 42]
What are the values of x and y when the following statements are executed?
int a = 63, b = 36;
boolean x = (a > b) ? a : b;
int y = (a < b) ? a : b;
What is meant by the precedence of operators?
Operators with higher precedence are evaluated before operators with relatively lower precedence. Arrange the operators given below in order of higher precedence to lower precedence.
- &&
- %
- >=
- ++
Give the output of the following method:
public static void main (String [] args)
{
int a = 5;
a++;
System.out.println(a);
a -= (a--) − (--a);
System.out.println(a);
}
Evaluate the value of n. if value of p = 5, q = 19
int n = (q – p) > (p – q) ? (q – p) : (p – q)
Avichal solutions for Computer Applications [English] Class 10 ICSE 1.4 Operators in Java EXERCISES [Pages 43 - 44]
Multiple Choice Questions:
Which of the following is the correct precedence of logical operators?
!, &&, ||
&&, !, ||
||, !, &&
&&, ||, !
Choose the odd one out from the following:
>
==
&&
<
Given: String st = (a>= 90)? "Excellent": "Best";
Predict the output, when a = 90.
Best
Excellent: Best
Best: Excellent
Excellent
Choose the odd one out from the following:
Unary operator
Binary operator
Ternary operator
Bitwise operator
Given: x + = x++ + ++ x + − − x
Find the value, when x = 5.
23
21
22
24
State whether the following statements are 'True' or 'False':
The precedence of operators in Java follows BODMAS.
True
False
The output of a++ will be 1, if int a = -1.
True
False
The relational operators always result in terms of 'True' or 'False'.
True
False
Given: int m = 5; m* = 5; then the value stored in m results in 55.
True
False
The statement (a>b) && (a>c) uses a logical operator.
True
False
If int a = 27, b = 4, c = O; then c = a%b; results in 3.
True
False
The statement p + = 5 means p = p*5.
True
False
In the precedence of logical operators; NOT is followed by AND.
True
False
Write the Java expression for the following:
`root3 (ab + cd)`
Write the Java expression for the following:
p3 + q4 − `1/2`r
Write the Java expression for the following:
`(−b+sqrt(b^2 - 4ac))/(2a)`
Write the Java expression for the following:
`(0.05 - 2y^3)/((x - y))`
Write the Java expression for the following:
`sqrt(mm) + root3 ((m + n))`
Write the Java expression for the following:
`3/4 (a + b) - 2/5 ab`
Write the Java expression for the following:
`3/8sqrt((b^2 + c^3))`
Write the Java expression for the following:
`root3 (a) + b^2 - root3c`
Write the Java expression for the following:
`sqrt(a + b^2 + c^3)/3`
Write the Java expression for the following:
`sqrt(3x + x^2)/((a + b))`
Write the Java expression for the following:
z = x3 + y3 − `y/z^3`
Write the Java expression for the following:
q = `1/sqrt(a + b) + 3/c^2`
Predict the output:
int c = (3<4)? 3*4:3+4;
Predict the output:
int a = 14, b = 4;
boolean x = (a>b)? true: false;
Predict the output:
int x = 90;
char c = (x<=90)? 'Z':'I';
Predict the output:
int a = 18; int b = 12;
boolean t = (a>20 && b< 15)? true:false;
Predict the output:
c = (val + 550 < 1700)? 200: 400;
if: val = 1000
Predict the output:
c = (val + 550 < 1700)? 200: 400;
if: val = 1500
Answer the following questions:
What is an operator?
What are the three main types of operators? Name them.
How is Java expression different from statement?
Explain the following with one example.
Arithmetic operator
Explain the following with one example.
Relational operator
Explain the following with one example.
Logical operator
Explain the following with one example.
Ternary operator
Write a difference between unary and binary operator.
Distinguish between Postfix increment and Prefix increment.
Distinguish between Postfix decrement and Prefix decrement.
Distinguish between (p != q) and !(p == q).
What is the difference between / and % operator?
What is the difference between = and ==?
What will be the output of the following code?
int k = 5, j = 9;
k += k++ - ++j + k;
System.out.println("k=" + k);
System.out.println("j="+ j);
What will be the output of the following code?
If int y = 10 then find int z = ( ++y * (y++ + 5));
Give the output of the following expression:
a+= a++ + ++a + -- a + a--; when a = 7;
What is the value of y after evaluating the expression given below?
y+= ++y + y-- + --y; when int y=8;
Rewrite the following program segment using if-else statements instead of the ternary operator:
String grade = (mark >= 90) ? “A” : (mark >= 80) ? “B” : “C”;
Rewrite the following program segment using if-else statements instead of the ternary operator.
commission = (sale > 5000) ? (sale * 10) / 100 : 0;
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.
Rewrite the following program segment using if-else statements instead of the ternary operator.
s = (a+b < c || a + c <= b || b + c <= a) ? "Triangle is not possible": "Triangle is possible";
Rewrite the following program segment using if-else statements instead of the ternary operator.
c = (x >= 'A' && x <= 'Z') ? "Upper Case Letter" : "Lower Case Letter";
Rewrite the following using ternary operator.
if (x % 2 == 0)
System.out.println("Even");
else
discount = bill * 5.0 / 100;
Rewrite the following using ternary operator :
if (bill > 10000)
discount = bill * 10.0 / 100;
else
discount = bill * 5.0 / 100;
Rewrite the following using ternary operator.
if (income < 10000)
tax = 0;
else
tax = 12;
Rewrite the following using ternary operator.
if (a > b)
{
if (a > c)
g = a;
else
g = c;
}
if (b > c)
g = b;
else
g = c;
Rewrite the following using ternary operator.
if (p >= 4750)
k = p * 5 / 100;
else
k = p * 10 / 100;
Solutions for 1.4: Operators in Java
![Avichal solutions for Computer Applications [English] Class 10 ICSE chapter 1.4 - Operators in Java Avichal solutions for Computer Applications [English] Class 10 ICSE chapter 1.4 - Operators in Java - Shaalaa.com](/images/computer-applications-english-class-10-icse_6:1e1eb1b47d2b4696b609e5cd9260118f.jpg)
Avichal solutions for Computer Applications [English] Class 10 ICSE chapter 1.4 - Operators in Java
Shaalaa.com has the CISCE Mathematics Computer Applications [English] Class 10 ICSE CISCE solutions in a manner that help students grasp basic concepts better and faster. The detailed, step-by-step solutions will help you understand the concepts better and clarify any confusion. Avichal solutions for Mathematics Computer Applications [English] Class 10 ICSE CISCE 1.4 (Operators in Java) include all questions with answers and detailed explanations. This will clear students' doubts about questions and improve their application skills while preparing for board exams.
Further, we at Shaalaa.com provide such solutions so students can prepare for written exams. Avichal textbook solutions can be a core help for self-study and provide excellent self-help guidance for students.
Concepts covered in Computer Applications [English] Class 10 ICSE chapter 1.4 Operators in Java are Introduction of Operators in Java, Expression and Statement, Types of Operators.
Using Avichal Computer Applications [English] Class 10 ICSE solutions Operators in Java exercise by students is an easy way to prepare for the exams, as they involve solutions arranged chapter-wise and also page-wise. The questions involved in Avichal Solutions are essential questions that can be asked in the final exam. Maximum CISCE Computer Applications [English] Class 10 ICSE students prefer Avichal Textbook Solutions to score more in exams.
Get the free view of Chapter 1.4, Operators in Java Computer Applications [English] Class 10 ICSE additional questions for Mathematics Computer Applications [English] Class 10 ICSE CISCE, and you can use Shaalaa.com to keep it handy for your exam preparation.