Skip to content
Related Articles

Related Articles

Improve Article
Save Article
Like Article

Java | Operators | Question 4

  • Last Updated : 28 Jun, 2021




class Test {
    public static void main(String args[])  {
       System.out.println(10*20 + "GeeksQuiz");
       System.out.println("GeeksQuiz" + 10*20);
   
}

(A)

10*20GeeksQuiz
GeeksQuiz10*20

(B)

200GeeksQuiz
GeeksQuiz200

(C)

200GeeksQuiz
GeeksQuiz10*20

(D)

1020GeeksQuiz
GeeksQuiz220


Answer: (B)

Explanation: Precedence of * is more than +.

Quiz of this Question

My Personal Notes arrow_drop_up
Recommended Articles
Page :