Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

explin the logic plz...

 
Priya dharshini
Ranch Hand
Posts: 78
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
public class Test{
public sttic void main(String []args){
byte[][] big= new byte[7][7];
byte[][] b=ne byte[2][1];
byte b3=5;
byte b2 [][][][][=new bye[2][3][1][2];
}
}

Which of the following lines of code could be inserted at line 7,nd still allow the code to compile?(choose 4)

A.b2[0][1]=b;
B.b[0][0]=b3;
C.b2[1][1][0]=b[0][0];
D.b2[1][2][0]=b;
E.b2[0][1][0][0]=b[0][0];
F.b2[0][1]=big;

Ans:A,B,E,F
 
Barry Gaunt
Ranch Hand
Posts: 7729
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1. Please place your code between tags to preserve formatting. There is a special button marked "CODE" that you can use.

2. Please edit your code because it is obviously full of typing errors. You can use the icon that looks like a pencil and paper for that purpose.

Thanks
-Barry
 
Priya dharshini
Ranch Hand
Posts: 78
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry..Hereafter i will post inside .I am new member so that i don't know the method.Thank u.
 
Sherry Jacob
Ranch Hand
Posts: 128
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Barry Gaunt:
1. Please place your code between tags to preserve formatting. There is a special button marked "CODE" that you can use.

2. Please edit your code because it is obviously full of typing errors. You can use the icon that looks like a pencil and paper for that purpose.

Thanks
-Barry


Ya Barry's right...follow his comments...he taught me to be professional in posting messages on the site.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic