
String and type wrappers

Quiz
•
Computers
•
9th Grade
•
Hard
RAVINDRA INDURTHI
Used 1+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
String in Java is a?
class
object
variable
character array
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of these method of String class can be used to test to strings for equality?
isequal()
isequals()
equal()
equals()
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following statements are incorrect?
String is a class
Strings in java are mutable
Every string is an object of class String
Java defines a peer class of String, called StringBuffer, which allows string to be altered
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Java program?
class string_demo
{
public static void main(String args[])
{
String obj = "I" + "like" + "Java";
System.out.println(obj);
}
}
I
like
Java
IlikeJava
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Java program?
class output
{
public static void main(String args[])
{
StringBuffer s1 = new StringBuffer("Hello");
StringBuffer s2 = s1.reverse();
System.out.println(s2);
}
}
Hello
olleH
HelloolleH
olleHHello
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following Java program?
class output
{
public static void main(String args[])
{
StringBuffer c = new StringBuffer("Hello");
c.delete(0,2);
System.out.println(c);
}
}
He
Hel
lo
llo
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of these method of class StringBuffer is used to find the length of current character sequence?
length()
Length()
capacity()
Capacity()
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
JavaScript Cert Prep

Quiz
•
9th - 12th Grade
10 questions
Python Arithmetic Operators

Quiz
•
8th - 9th Grade
14 questions
Тест по JavaScript

Quiz
•
9th Grade
10 questions
PBO XII RPL

Quiz
•
9th - 12th Grade
14 questions
Unit 5: Input in Java

Quiz
•
9th - 10th Grade
10 questions
Java Strings

Quiz
•
1st Grade - Professio...
15 questions
Programación con Java

Quiz
•
9th - 11th Grade
12 questions
Java Basics

Quiz
•
9th - 12th Grade
Popular Resources on Wayground
10 questions
Video Games

Quiz
•
6th - 12th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
10 questions
UPDATED FOREST Kindness 9-22

Lesson
•
9th - 12th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
20 questions
US Constitution Quiz

Quiz
•
11th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
Discover more resources for Computers
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
20 questions
Analog vs Digital

Quiz
•
9th - 12th Grade
10 questions
Exploring Cybersecurity Techniques and Threats

Interactive video
•
6th - 10th Grade
10 questions
Understanding the Internet and Data Transmission

Interactive video
•
7th - 12th Grade