Search Header Logo

Operators and Expressions

Authored by Sandeep M

Computers

9th - 12th Grade

Used 1+ times

Operators and Expressions
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

10 questions

Show all answers

1.

MULTIPLE SELECT QUESTION

30 sec • 1 pt

Which of the following are arithmetic operators in Java?

2.

MULTIPLE SELECT QUESTION

30 sec • 1 pt

Which of the following are examples of relational operators in Java?

3.

MULTIPLE SELECT QUESTION

30 sec • 1 pt

Which of the following are examples of logical operators in Java?

4.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Which of the following operators can be used with strings in Java?

*

5.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

What is the value stored in x, y and z, after the following set of statements are executed:

y = 10;

z = 15;

x = ++y + z-- + y-- + z++;

x = 51, y = 10, z = 15

x = 50, y = 9, z = 15
x = 50, y = 10, z = 15
x = 49, y = 9, z = 16

6.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

In Java, consider the following code snippet:

int a = 10;

int b = 10;

int c = 5;

boolean x = (a < b) && (a >= c);

boolean y = (a != b) || (a > c);

Now, what are the values of x and y?

x : true, y : true

x : true, y : false

x : false, y : false

x : false, y : true

7.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

The ternary operator in Java is a type of

Logical operator

Arithmetic operator

Relational operator

Conditional operator

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Microsoft

Continue with Microsoft

or continue with

Facebook

Facebook

Apple

Apple

Others

Others

Already have an account?