Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I need some assistance, I think I am making this more complicated than it really is, this is for Java. public class ArrayLab { public

I need some assistance, I think I am making this more complicated than it really is, this is for Java.

public class ArrayLab { public static void main(String[] args) { int[][] stuff = { {33, 92, 54}, {22, 43, 90}, {26, 85, 21}, {75, 14, 66}, { 8, 49, 89} }; // in all of the below 4 tasks, do not "hard code" the // array dimentions (i.e. "4" or "3") but rather use the // .length property of the array or individual row.

// 1. print out the array contents going across the rows // but from the last row to the first: // 8, 49, 89 // 75, 14, 66 // etc.....

// 2. print out the array contents going down the columns // from the first column to the last. in other words: // 33, 22, 26, 75, 8 // 92, 43, 85, 14, 49 // etc....

// 3. print out the array going up the columns, starting // with the last column and last row, and working backwards // to the first column and row. in other words: // 89, 66, 21, 90, 54 // 49, 14, 85, 43, 90 // etc....

// 4. print out the array contents in "normal" order, // in other words: // 33, 92, 54, // 22, 43, 90 // etc.... } }

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Fundamentals Of Database Systems

Authors: Sham Navathe,Ramez Elmasri

5th Edition

B01FGJTE0Q, 978-0805317558

Students also viewed these Databases questions