Save
Upgrade to remove ads
Busy. Please wait.
Log in with Clever
or

show password
Forgot Password?

Don't have an account?  Sign up 
Sign up using Clever
or

Username is available taken
show password


Make sure to remember your password. If you forget it there is no way for StudyStack to send you a reset link. You would need to create a new account.
Your email address is only used to allow you to reset your password. See our Privacy Policy and Terms of Service.


Already a StudyStack user? Log In

Reset Password
Enter the associated with your account, and we'll email you a link to reset your password.
focusNode
Didn't know it?
click below
 
Knew it?
click below
Don't Know
Remaining cards (0)
Know
0:00
Embed Code - If you would like this activity on your web page, copy the script below and paste it into your web page.

  Normal Size     Small Size show me how

OOP LEC [FA2]

CS0070

QuestionAnswer
Consider the following codes: int x=2; System.out.println(x--); What will be the EXACT output? Group of answer choices 1 2 4 3 2
Checks if the value of left operand is less than the value of right operand, if yes then condition becomes true. Group of answer choices < > < >> <
Consider the following codes: int x=4; System.out.println(x--); What will be the EXACT output? Group of answer choices 3 4 1 2 4
What will be the output of the following program System.out.println(10 * 5 + 100 * (25 * 11) / (25 * 10) * 10 - 5 + 7 % 2); int zx = (10 * 5 + 100 * (25 * 11)); int yz = ((25 * 10) * 10 - 5 + 7 % 2); System.out.println(zx / yz); 1146 11
The _____ loop is for traversing items in a collection Group of answer choices do while for while foreach foreach
An operator that decreases the value of operand by 1. Group of answer choices 1- -- – -1 --
The for loop is for traversing items in a collection Group of answer choices false true false
What will be the output of the following program? int i = 34.0; int j = 7; int k = i % j; System.out.println("k = " + k ); Error
What is the operator in which The left operands value is moved right by the number of bits specified by the right operand and shifted values are filled up with zeros. Group of answer choices < >>> >> << >>
Consider the following codes: int x=1; System.out.println(x++); What will be the EXACT output? Group of answer choices 1 2 3 4 1
The ______ loop executes a given statement or a block of statements for a definite number of times. Group of answer choices do while for while for
Consider the following codes: int x=3; System.out.println(x++); What will be the EXACT output? Group of answer choices 1 3 4 2 3
What does a Two-Dimensional Array do? Group of answer choices It creates two arrays at once. It creates an array with only two elements. None of the choices It forms a tabular, two dimensional arrangement. It forms a tabular, two dimensional arrangement
The break statement causes the program flow to exit from the body of the switch construct. Group of answer choices false true True
What is the result of -7%2 Group of answer choices -2 2 1 -1 -1
It subtracts right operand from the left operand and assign the result to left operand. Group of answer choices *- /= += -= -=
It divides left operand with the right operand and assign the result to left operand. Group of answer choices /= -= += *- /=
The case statement is used to conditionally perform statements based on an integer expression Group of answer choices true false False
Which of the following declares an array of int named img? Group of answer choices int img; new int img[]; int img = int[]; int[] img; int[] img;
Consider the following codes: int x=4; System.out.println(7>>2); What will be the EXACT output? Group of answer choices 1 4 3 2 1
The label identifies any valid statement to which control must be transferred Group of answer choices true false True
The while loop executes a given statement or a block of statements for a definite number of times. Group of answer choices true false False
What does the code output? int p=0; while (p<0) { System.out.println("hi"); } Group of answer choices It will output "hi" infinitely hi It won't output anything It will output an error! It won't output anything
int x=2; System.out.println(--x); What will be the EXACT output? Group of answer choices 4 1 3 2 1
What is the output of the following code fragment: int[] zip = new int[5]; zip[0] = 7; zip[1] = 3; zip[2] = 4; zip[3] = 1; zip[4] = 9; System.out.println( zip[ 2 + 1 ] ); Group of answer choices 4 4 3 1 3 7 1
What is the output of the following code fragment? for ( int j = 5; j > -5; j-- ) System.out.print( j + " " ); System.out.println( ); 5 4 3 2 1 0 -1 -2 -3 -4 -5 -4 -3 -2 -1 0 5 4 3 2 1 0 5 4 3 2 1 0 -1 -2 -3 -4 -5 5 4 3 2 1 0 -1 -2 -3 - 4
True or False. The first expression in the for loop syntax is the initialization of the counter variable. True
Consider the following codes: int x=3; System.out.println(--x); What will be the EXACT output? 2
The ____ statement enables your program to selectively execute other statements, based on some criteria if
An operator that can be used to add String objects. Group of answer choices +
An operator that subtracts right-hand operand from left-hand operand. -
[True or False] The lbl identifies any valid statement to which control must be transferred false
decrease the value of the variable by a particular number by which it was decreased decrement operators
The _____ statement performs a different set of statements if the expression is false. else
The _______ loop facilitates evaluation of condition or expression at the end of the loop to ensure that the statements are executed at least once do while
Which is first incremented and then used? Group of answer choices x++ +x x+ ++x ++x
[True or False] The statements associated with else keyword is executed if the value of the switch variable does not match any of the case constants. false
Created by: AdoKwatro
 

 



Voices

Use these flashcards to help memorize information. Look at the large card and try to recall what is on the other side. Then click the card to flip it. If you knew the answer, click the green Know box. Otherwise, click the red Don't know box.

When you've placed seven or more cards in the Don't know box, click "retry" to try those cards again.

If you've accidentally put the card in the wrong box, just click on the card to take it out of the box.

You can also use your keyboard to move the cards as follows:

If you are logged in to your account, this website will remember which cards you know and don't know so that they are in the same box the next time you log in.

When you need a break, try one of the other activities listed below the flashcards like Matching, Snowman, or Hungry Bug. Although it may feel like you're playing a game, your brain is still making more connections with the information to help you out.

To see how well you know the information, try the Quiz or Test activity.

Pass complete!
"Know" box contains:
Time elapsed:
Retries:
restart all cards