
PU Day 1 assessments - Srinivas's batch
Authored by training atomm
Professional Development
Professional Development
Used 1+ times

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 CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Java program?
class selection_statements
{
public static void main(String args[])
{
int var1 = 5;
int var2 = 6;
if ((var2 = 1) == var1)
System.out.print(var2);
else
System.out.print(++var2);
}
}
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Java program?
class TestOutput
{
public static void main(String args[])
{
int a = 10;
int b = 20;
if (a < b)
System.out.print(a + b);
else
System.out.print(a - b);
}
}
30
-10
10
20
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Java program?
class CompareValues
{
public static void main(String args[])
{
int x = 15;
int y = 15;
if (x == y)
System.out.print("Equal");
else
System.out.print("Not Equal");
}
}
Equal
Error
Not Equal
None of the above
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Java program?
class LoopExample
{
public static void main(String args[])
{
for (int i = 0; i < 3; i++)
System.out.print(i);
}
}
}
321
None
123
012
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How many times will the following do-while loop execute?
int i = 1;
do {
System.out.println(i);
i++;
} while(i <= 5);
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Java program?
class StringComparison
{
public static void main(String args[])
{
String str1 = "Hello";
String str2 = "Hello";
if (str1.equals(str2))
System.out.print("Match");
else
System.out.print("No Match");
}
}
None of the above
Match
Error
No Match
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Java program?
class ConditionalCheck
{
public static void main(String args[])
{
int num = 8;
if (num % 2 == 0)
System.out.print("Even");
else
System.out.print("Odd");
}
}
Even
Odd
None of the above
Error
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
14 questions
Fundamental Python
Quiz
•
Professional Development
12 questions
Data Sourcing, Security & Modelling
Quiz
•
Professional Development
10 questions
July Knowledge Check
Quiz
•
Professional Development
13 questions
Quiz JC ( By Jojo 5 )
Quiz
•
Professional Development
9 questions
Dysgraphia
Quiz
•
Professional Development
10 questions
Multiple Responses
Quiz
•
Professional Development
14 questions
operators in python
Quiz
•
Professional Development
10 questions
Current Affairs 2022
Quiz
•
Professional Development
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
29 questions
Alg. 1 Section 5.1 Coordinate Plane
Quiz
•
9th Grade
22 questions
fractions
Quiz
•
3rd Grade
11 questions
FOREST Effective communication
Lesson
•
KG
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade