
Quiz 2
Authored by Ms. Asst.Prof
Computers
University
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 is the length of the following array byte[] data= {12, 34, 9, 0, 62, 88 };
1
5
6
12
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code fragment:
int[] arr= {2, 4, 6, 8, 10, 1, 3, 5, 7, 9};
for(int index=0; index<5; index++)
System.out.print(arr[index]+ " ");
2 4 6 8
2 4 6 8 10
2 4 6 8 10 1
2 4 6 8 10 1 3 5 7 9
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
int[] arr = { 2, 4, 6, 8, 10, 1, 3, 5, 7, 9};
for(int index=0; index<arr.length; index++)
System.out.println(arr[index]+" ");
2 4 6 8
2 4 6 8 10
2 4 6 8 10 1
2 4 6 8 10 1 3 5 7 9
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of these method of class String is used to extract a single character from a String object?
CHARTAT()
charat()
chatAt()
CharAt()
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of these operators can be used to concatenate two or more String objects?
+
+=
&
||
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which is the output of the following code fragement
int[] egArray = { 2, 4, 6, 8, 10, 1, 3, 5, 7, 9 };
for(int index=0; index<egArray.length; index=index+2)
System.out.print(egArray[index]+ " ");
2 4 6 8 10 1 3 5 7 9
4 8 1 5 9
2 6 10 3 7
2 6 10 3 7 0
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Does a programmer always know long an array will be when the program is being written?
Yes--the program will not compile without the length being declared.
No-- the array object is created when the program is running, and the length might change from run to run.
Yes-- otherwise the program will not run correctly.
No--arrays can grow to whatever length is needed.
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
10 questions
E-Commerce 1
Quiz
•
University
12 questions
Javascript
Quiz
•
University
10 questions
Programación II Parte 5
Quiz
•
University
10 questions
Quiz Ke 8 alprog if-09
Quiz
•
University
10 questions
Clase 1 TM Scilab
Quiz
•
University
15 questions
python basics
Quiz
•
11th Grade - University
10 questions
CSNP-04103 Chapter 6 - Functions
Quiz
•
University
12 questions
Printf, scanf
Quiz
•
University
Popular Resources on Wayground
7 questions
History of Valentine's Day
Interactive video
•
4th Grade
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
15 questions
Valentine's Day Trivia
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
Discover more resources for Computers
18 questions
Valentines Day Trivia
Quiz
•
3rd Grade - University
12 questions
IREAD Week 4 - Review
Quiz
•
3rd Grade - University
23 questions
Subject Verb Agreement
Quiz
•
9th Grade - University
5 questions
What is Presidents' Day?
Interactive video
•
10th Grade - University
7 questions
Renewable and Nonrenewable Resources
Interactive video
•
4th Grade - University
20 questions
Mardi Gras History
Quiz
•
6th Grade - University
10 questions
The Roaring 20's Crash Course US History
Interactive video
•
11th Grade - University
17 questions
Review9_TEACHER
Quiz
•
University