What is wrong with the following Java variable declaration?
int 1stNumber = 23;
Java Quizathon
Quiz
•
Computers
•
University
•
Medium
Keerthi GJ
Used 2+ times
FREE Resource
50 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
What is wrong with the following Java variable declaration?
int 1stNumber = 23;
There is no data type called 'int'
Variable names can not start with a digit
Variable names can not contain digits
Number 23 can not be stored in an int
2.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
Following set of data items are to be stored about a student
a. Students name
b. Students current age in years
c. Students weight in kg
d. Students gender
Which of the following data types will match best with these
a. String
b. int
c. String
d. String
a. String
b. float
d. int
d. int
a. String
b. int
c. float
d. boolean
a. String
b. int
c. float
d. char
3.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
Which of the following data is the 'smallest' data type that can be used to hold the 'distance between Earth to Mars' in km.
(Average distance between Earth and March is 234,460,000 km)
byte
int
long
short
4.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
What is the output of the following code?
x is 0
x is 1
x is 2
x is 3
x is 4
5.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
Java is a
Procedure Oriented Language
Structure Oriented Language
Object_Oriented Language
Machine Language
6.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
The name of the following should be the file name in Java
Object Name
Variable Nam
Class Name
Array Name
7.
MULTIPLE CHOICE QUESTION
20 sec • 1 pt
The name of the following should be the file name in Java
Object Name
Variable Nam
Class Name
Array Name
52 questions
ICT CBP Q3 Periodical Test
Quiz
•
9th Grade - University
50 questions
html css and javascript
Quiz
•
University
50 questions
OOP PRELIM
Quiz
•
University
50 questions
WEBKA
Quiz
•
University
50 questions
BSIT1104 CP PL Exam
Quiz
•
University
50 questions
PF201: SCCPF2012223
Quiz
•
University
50 questions
LATIHAN SOAL
Quiz
•
10th Grade - University
50 questions
SKILL QUIZ
Quiz
•
University
15 questions
Multiplication Facts
Quiz
•
4th Grade
20 questions
Math Review - Grade 6
Quiz
•
6th Grade
20 questions
math review
Quiz
•
4th Grade
5 questions
capitalization in sentences
Quiz
•
5th - 8th Grade
10 questions
Juneteenth History and Significance
Interactive video
•
5th - 8th Grade
15 questions
Adding and Subtracting Fractions
Quiz
•
5th Grade
10 questions
R2H Day One Internship Expectation Review Guidelines
Quiz
•
Professional Development
12 questions
Dividing Fractions
Quiz
•
6th Grade