Question: Name your program Assignment5.java Have your program output your first and last name Email me your source code (Assignment5.java). Please remember to use my tjl274@email.vccs.edu
- Name your program Assignment5.java
- Have your program output your first and last name
- Email me your source code (Assignment5.java). Please remember to use my "tjl274@email.vccs.edu" address
- Write a program that prompts the user enter an int value.
- Create a two dimensional array of int that size. For example, if the user types in 3, then you are to create a 3 by 3 array
- Using a Random object, set each element of your array to be either zero or one
- Output the array with each row on a line (see example output below)
- Go through all the rows of your array and find the row with the most ones. Output the index and sum of this row. (see example below). If more than one row has the most ones, you only need to output the index and sum for the first row.
- Go through all the columns of your array and find the column with the most ones. Output the index and sum of this column. (see example below). If more than one column has the most ones, you only need to output the index and sum for the first column.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
