5 years ago in Java Strings

Which of these method of String class is used to obtain character at specified index?

[A] char()
[B] Charat()
[C] charat()
[D] charAt()
Loading...
Next Question

Overall Stats

Attempted 435
Correct 219
Incorrect 56
Viewed 160

Answers

Guest
Guest
Shamsa hafeez
Shamsa hafeez - 4 days ago

Shamsa hafeez from Lahore, Pakistan is saying charAt() is correct answer

bruh
bruh - 1 month ago

bruh from Guwahati, India is saying charAt() is correct answer

Assaad Amine
Assaad Amine - 1 month ago

Assaad Amine from Casablanca, Morocco is saying Charat() is correct answer

Vaibhav Bisht
Vaibhav Bisht - 1 month ago

Vaibhav Bisht from Dehradun, India is saying charat() is correct answer

Zo Go
Zo Go - 1 month ago

Zo Go from Casablanca, Morocco is saying charAt() is correct answer

Related Questions

What is the output of the code ?
public class AQuestion{

      private int i = j;

      private int j = 10;

      public static void main(String args[]){

            System.out.println((new AQuestion()).i);

      }

}

  • [A] Compiler error complaining about access restriction of private variables of AQuestion.
  • [B] Compiler error complaining about forward referencing.
  • [C] No error - The output is 0;
  • [D] No error - The output is 10;

Which of the following statements are incorrect?

  • [A] String is a class
  • [B] Strings in java are mutable.
  • [C] Every string is an object of class String.
  • [D] Java defines a peer class of String, called StringBuffer, which allows string to be altered.