apcsa-1D array

apcsa-1D array

11th Grade

10 Qs

quiz-placeholder

Similar activities

AP CS A Unit 6 Quiz PRACTICE

AP CS A Unit 6 Quiz PRACTICE

9th - 12th Grade

10 Qs

Unit 6 Arrays

Unit 6 Arrays

10th - 12th Grade

14 Qs

Java Strings

Java Strings

9th - 12th Grade

12 Qs

AP CS practice 2

AP CS practice 2

11th Grade - University

12 Qs

AP Computer Science A Unit 6 Lesson 1 (Introduction)

AP Computer Science A Unit 6 Lesson 1 (Introduction)

10th - 12th Grade

5 Qs

Xб_сор

Xб_сор

9th - 12th Grade

10 Qs

Two-Dimensional Array

Two-Dimensional Array

9th - 12th Grade

12 Qs

Binary search

Binary search

11th Grade

5 Qs

apcsa-1D array

apcsa-1D array

Assessment

Quiz

Computers

11th Grade

Hard

Created by

lin fu

Used 9+ times

FREE Resource

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Consider the following code segment. int[] arr = {1, 2, 3, 4, 5};

Which of the following code segments would correctly set the first two elements of array arr to 10 so that the new value of array arr will be {10, 10, 3, 4, 5} ?

arr[0] = 10;

arr[1] = 10;

arr[1] = 10;

arr[2] = 10;

arr[0, 1] = 10;

arr[1, 2] = 10;

arr = 10, 10, 3, 4, 5;

2.

MULTIPLE CHOICE QUESTION

2 mins • 1 pt

Media Image

I only

II only

III only

I and II

I and III

3.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

Media Image

{10, 20, 30, 70, 120}

{10, 20, 50, 90, 50}

{10, 20, 50, 90, 140}

{10, 30, 60, 100, 50}

{10, 30, 60, 100, 150}

4.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

Media Image

2

1

0

-4

5.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

Media Image

I only

II only

I and II

I and III

I and II and III

6.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

Media Image

In the for loop header, the initial value of j should be 0.

In the for loop header, the initial value of j should be 2.

The for loop condition should be j < fibs.length - 1.

The for loop condition should be j < fibs.length + 1.

7.

MULTIPLE CHOICE QUESTION

3 mins • 1 pt

Media Image

for (int y = 0; y <= arr.length; y++)

for (int y = 0; y < arr.length; y++)

for (int y = x; y < arr.length; y++)

for (int y = x + 1; y < arr.length; y++)

for (int y = x + 1; y <= arr.length; y++)

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?