String Function Revision

String Function Revision

10th Grade

8 Qs

quiz-placeholder

Similar activities

String

String

10th - 12th Grade

10 Qs

week 1 basic java coding language

week 1 basic java coding language

9th - 12th Grade

12 Qs

java variables 1

java variables 1

9th - 12th Grade

13 Qs

AP CSA Inheritance Polymorphism

AP CSA Inheritance Polymorphism

10th - 12th Grade

8 Qs

Java String Methods

Java String Methods

10th - 12th Grade

10 Qs

String Warm Up

String Warm Up

8th - 12th Grade

12 Qs

Sains Komputer (Java) 1: Sintaks Asas & Pembolehubah

Sains Komputer (Java) 1: Sintaks Asas & Pembolehubah

10th Grade - University

10 Qs

If-Else in Java

If-Else in Java

9th - 12th Grade

10 Qs

String Function Revision

String Function Revision

Assessment

Quiz

Computers

10th Grade

Medium

Created by

Ruchita Dave

Used 1+ times

FREE Resource

8 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

String str = "Information Technology";
int p;
p = str.indexOf('n');
System.out.println(p);

p

n

1

None of the above

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

String str1 = "Information Technology"; 
String str2 = "information technology"; 
boolean p = str1.equalsIgnoreCase(str2); 
System.out.println("The result is " + p);
The result is true
The result is false
The result is 0
The result is 1

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

String x = "Vision";
String y = "2020";

System.out.println(x + y);

Vision 2020

2020

Vision2020

None of the above

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

String S1 = "Computer World";
String S2 = "COMPUTER WORLD";
System.out.println(S1 + " equalsIgnoreCase "+ S2 + " " + S1.equalsIgnoreCase(S2));
Computer World 
COMPUTER WORLD 
Computer World 
equalsIgnoreCase 
COMPUTER WORLD 
true
Computer World 
equalsIgnoreCase 
Computer World 
false

true

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

String n = "Computer Knowledge";
System.out.println(n.substring(2,5));
omput
mput
mputer Knowledge
mpu

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt


String n = "Computer Applications"; 
System.out.println(n.endsWith("e"));

true

false

0

None of the above

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

String x[] = {"SAMSUNG", "NOKIA", "SONY", "MICROMAX", "BLACKBERRY"};

System.out.println(x[3].length());

8

4

7

5

8.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

"ACHIEVEMENT".replace('E', 'A')

ACHIAVAMANT
ACHIAVEMANT
ACHIAVAMNT
ACHIEVAMANT