MCQ Single Best Answer Easy

QWhat do the following functions return for:

// Give the output of the following program fragment:
//What do the following functions return for:
class MCQClass {
	public static void main(String args[]){
		String x = "hello";
		String y = "world";
		System.out.println(x + y);
		System.out.println(x.length());
		System.out.println(x.charAt(3));
		System.out.println(x.equals(y));
	}
}

ID: #22216 Introduction in String Java 65 views
Question Info
#22216Q ID
EasyDifficulty
Introduction in String JavaTopic

Choose the Best Option

Click any option to instantly check if you're correct.

  • A
    helloworld
    5
    l
    false
  • B
    hello world
    5
    o
    false
Correct Answer: Option A

Explanation

Share This Question

Challenge a friend or share with your study group.