Java Array

Java Array

University

10 Qs

quiz-placeholder

Similar activities

Workshop_quiz_on Sk-learn

Workshop_quiz_on Sk-learn

University

15 Qs

Forum Activity Tech quiz

Forum Activity Tech quiz

University

15 Qs

ASSESSING HARDWARE

ASSESSING HARDWARE

University

10 Qs

MAD Unit 5 T1

MAD Unit 5 T1

University

10 Qs

Quizziz 2

Quizziz 2

University

10 Qs

Data Literacy Quizizz

Data Literacy Quizizz

6th Grade - University

15 Qs

PPL 223 - (QUIZ 3) Data Types and Structures

PPL 223 - (QUIZ 3) Data Types and Structures

University

15 Qs

Borders and Shades in Word 2010 Quiz

Borders and Shades in Word 2010 Quiz

10th Grade - University

12 Qs

Java Array

Java Array

Assessment

Quiz

Information Technology (IT)

University

Practice Problem

Medium

Created by

Adlina Anwar

Used 22+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the default value of an array element of type int in Java?

0

null

undefined

0.0

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you find the length of an array in Java?

  • arr.length()

arr.length

arr.size()

arr.capacity()

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is the wrong way to creates an array of strings?

A) String[] arr = new String[5];

B) String arr = new String[5];

C) String[] arr; arr = new String[5];

D) both A and C

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What is the output?

1

4

3

5

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you initialize an array with the values 1, 2, 3, 4, and 5?

int[] arr = {1, 2, 3, 4, 5};

int[] arr = new int[5]

int arr[] = {1, 2, 3, 4, 5};

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the index of the first element in an array?

-1

  • 1

0

2

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What will the following code print?

1

2

3

4

5

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?