
JAVA FUNDAMENTALS ASSESSMENT 1

Quiz
•
Computers
•
University
•
Medium
Gaurav Nayak
Used 12+ times
FREE Resource
40 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the output of the following Java program?
class Output {
public static void main(String args[]) {
int a = 1;
int b = 2;
int c;
int d;
c = ++b;
d = a++;
c++;
b++;
++a;
System.out.println(a + " " + b + " " + c); }
}
324
323
244
234
344
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the output of the following Java code?
class operators {
public static void main(String args[]) {
int x = 8;
System.out.println(++x * 3 + " " + x); }
24 8
27 9
24 9
27 8
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the output of the following Java code?
class Relational_operator {
public static void main(String args[]) {
int var1 = 5;
int var2 = 6;
System.out.print(var1 > var2); }
}
5
6
FALSE
TRUE
4.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the output of the following Java program?
class booloperators {
public static void main(String args[]) {
boolean var1 = true;
boolean var2 = false;
System.out.println((var1 & var2));
}
}
True
False
1
0
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the output of the following Java program?
public static void main(String args[]) {
char a = 65;
char b = 66;
char d = 68;
d--;
char c = --b;
a++;
System.out.println(b);
System.out.println(d);
System.out.println(b);
System.out.println(a);
}
}
A
C
A
B
B
A
B
A
B
A
C
A
A
D
A
B
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the output of the following Java program?
class squareroot {
public static void main(String args[]) {
double a, b;
a = 3.0;
b = 4.0;
double c = Math.sqrt(a * a + b * b);
System.out.println(c); } }
compilation error
25
7
5
7.
MULTIPLE SELECT QUESTION
1 min • 1 pt
Java is used for :
Web applications
Database connection
Games
Desktop applications
Text Editing
Create a free account and access millions of resources
Similar Resources on Wayground
39 questions
Java Midterm

Quiz
•
University
37 questions
Разработка мобильных приложений

Quiz
•
University
42 questions
Java Quiz 1

Quiz
•
University
40 questions
Quizz PTS Kelas XI Struktur Data Array

Quiz
•
11th Grade - University
35 questions
QUIZ PEMROGRAMAN 1 REG. PAGI

Quiz
•
University
45 questions
IP MIDTERM

Quiz
•
University
35 questions
quiz oop

Quiz
•
University
40 questions
Java Programming

Quiz
•
University
Popular Resources on Wayground
15 questions
Hersheys' Travels Quiz (AM)

Quiz
•
6th - 8th Grade
20 questions
PBIS-HGMS

Quiz
•
6th - 8th Grade
30 questions
Lufkin Road Middle School Student Handbook & Policies Assessment

Quiz
•
7th Grade
20 questions
Multiplication Facts

Quiz
•
3rd Grade
17 questions
MIXED Factoring Review

Quiz
•
KG - University
10 questions
Laws of Exponents

Quiz
•
9th Grade
10 questions
Characterization

Quiz
•
3rd - 7th Grade
10 questions
Multiply Fractions

Quiz
•
6th Grade