This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
    Bookmark Topic Watch Topic
  • New Topic

Multidimensional arrays

 
Shweta R Dhaneshwar
Ranch Hand
Posts: 35
  • 0
  • Mark post as helpful
  • send pies
  • Report post to moderator
Given the following,

which of the following lines of code could be inserted at line 7, and still allow the code to
compile? (Choose four that would work.)
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;

This example is from K&B.is there any easy way to solve such a problem.this is confusing...can anybody explain?
 
Faris A Saduli
Ranch Hand
Posts: 58
  • 0
  • Mark post as helpful
  • send pies
  • Report post to moderator
hi,
the following thing 'll compile
b[0][0] = b3;
b2[0][1] = b;
b2[0][1][0][0] = b[0][0];
b2[0][1] = big;
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24204
34
Chrome Eclipse IDE Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Report post to moderator
Please continue this discussion here.
 
I agree. Here's the link: http://aspose.com/file-tools
    Bookmark Topic Watch Topic
  • New Topic