
Computer Programming (Mid-term Exam)
Authored by NAZMIRUL IZZAD BIN NASIR
Other
University
Used 18+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
40 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which of these is used to start a single-line comment in Java?
#
//
/*
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which of these is not a valid data type in Java?
byte
int
string
float
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the correct way to declare a variable that stores a whole number?
int num;
whole num;
double num;
number num;
4.
MULTIPLE SELECT QUESTION
1 min • 1 pt
Which of the following will correctly output 10Java?
System.out.println(10 + Java);
System.out.println(10 + "Java");
System.out.println(Java + 10);
System.out.print(10 Java);
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What will be the result of System.out.println(2 + 3 * 4);?
20
14
24
10
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which of the following is used to store a single character?
char
String
boolean
int
7.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Java programs are compiled to an intermediate form called:
Source code
Assembly
Bytecode
Machine code
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?