Menu
Question Index
...

What will be the output of the following program?

public class DemoOnArrays
{
    public static void main(String args[])
    {
        int[] firstInput, secondInput;
        firstInput = new int[2];
        secondInput = 011;
        firstInput[0] = firstInput[1] = secondInput;
        System.out.print(firstInput[0] + firstInput[1]);
    }
}


11
22
33
55
Compilation Error or Runtime Error

Doubts

Problems

Topic: Creating Array Of Objects In Java

Read this topic
Take test on this topic

0
Wrong
Score more than 2 points

© meritcampus 2019

All Rights Reserved.

Open In App