πŸ“Š JAVA
Q. What is the output of the below Java program?
Code:
String str[] = {"A","B","C"};
int i=0;
do
{
  if(i>= str.length)
    break;
  System.out.print(str[i] + ",");
  i++;
}while(true);
  • (A) A,B,C,
  • (B) A,B,C
  • (C) Runtime Exception with Index Of Bounds Exception
  • (D) Compiler error
πŸ’¬ Discuss
βœ… Correct Answer: (A) A,B,C,

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
182
Total Visits
πŸ“½οΈ
4 y ago
Published
πŸŽ–οΈ
Ram Sharma
Publisher
πŸ“ˆ
89%
Success Rate