Java Quick Reference

Java Quick Reference

9th - 12th Grade

16 Qs

quiz-placeholder

Similar activities

8525 AQA GCSE  3.1.1 Pseudo-code

8525 AQA GCSE 3.1.1 Pseudo-code

10th - 11th Grade

14 Qs

Functions in C++

Functions in C++

11th Grade

20 Qs

B Words GCSE Computer Science

B Words GCSE Computer Science

1st - 10th Grade

15 Qs

Mrs O's Computer Architecture Quiz

Mrs O's Computer Architecture Quiz

KG - University

13 Qs

OOP 1 Undiksha

OOP 1 Undiksha

12th Grade - University

13 Qs

Visual Basic Assessment

Visual Basic Assessment

11th - 12th Grade

21 Qs

PRUEBA CORTA I - SISTEMA E INSTALACIÓN DE SOFTWARE I - U4

PRUEBA CORTA I - SISTEMA E INSTALACIÓN DE SOFTWARE I - U4

9th - 12th Grade

15 Qs

Java Quick Reference

Java Quick Reference

Assessment

Quiz

Computers

9th - 12th Grade

Medium

Created by

Chanel White

Used 8+ times

FREE Resource

AI

Enhance your content in a minute

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

16 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Constructs a new string object that represents the same sequence of characters as str

String(String str)

int length()

String substring(int from, int to)

Answer explanation

This method will allow you to create a new String object.

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Returns the number of characters in a String object

int length()

int long()

int getLength()

Integer(int value)

Answer explanation

This is used to get the length of a String object. It is not the same length method used on arrays.

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Returns substring(from, length())

String cutLength(String str)

String substring(int from)

String substring(int from, int to)

Answer explanation

This method will return a part of a string starting at the index indicated to the end of the string.

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Returns the index of the first occurrence of a string, returns -1 if not found

boolean equals(String other)

int compareTo(String str)

int numberOf(String str)

int indexOf(String str)

Answer explanation

This returns the index number of the first letter of the string you are looking for.

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Returns true if this is equal to other object, returns false if not equal

int equals(String other)

double equals(String other)

boolean equals(String other)

String equals(String other)

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Constructs a new integer object, represents the specified int value

Integer(int value)

integer(int value)

int x = value

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Returns the smallest value of an integer

getMinValue()

Integer.MAX_VALUE

Integer.MIN_VALUE

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?