Assignment Write a program that reads a 2D array of chars, checks, and corrects each char within this array, and print out the corrected 2D array. First the program will read the row count (rowCount) and column count (columnCount) of the 2D array, both as int values. Then, the chars constituting the 2D array will be read on a row-by-row basis. After reading the 2D array, the program will check and correct each char within the 2D array according to the rules below. This process MUST be done by using a void function by sending the appropriate cell of the 2D array with a call-by-reference fashion. • If the row index is an even number, a char can only be a lowercase English value. • If the row index is an odd number, a char can only be ?, 7', or X'. • Any incorrect value MUST be changed into Finally, the checked and corrected 2D array will be printed out to the screen. NOTE: Checking the correctness of a char and correcting it (if necessary) MUST be done in the function with a call-by-reference fashion to the relevant cell of the 2D array. Every other functionality MUST be done in the main function. ΔΕΛΗΓ function with a call-by-reference fashion to the relevant cell of the 2D array. Every other functionality MUST be done in the main function. Input Output 44 7927 AbcX D6F8 Cdbp X 25 gYT9a j71Xn 55 g__a _7_X_ 55 AFDHJ 0???x Kwhy 1 S???E KLO18 ???_ _why_ ???_

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter8: Arrays
Section: Chapter Questions
Problem 9PE
icon
Related questions
Question
Assignment
Write a program that reads a 2D array of chars, checks, and corrects each char within this array, and
print out the corrected 2D array. First the program will read the row count (rowCount) and column
count (columnCount) of the 2D array, both as int values. Then, the chars constituting the 2D array
will be read on a row-by-row basis.
After reading the 2D array, the program will check and correct each char within the 2D array
according to the rules below. This process MUST be done by using a void function by sending the
appropriate cell of the 2D array with a call-by-reference fashion.
• If the row index is an even number, a char can only be a lowercase English value.
• If the row index is an odd number, a char can only be ?, 7', or X'.
• Any incorrect value MUST be changed into
Finally, the checked and corrected 2D array will be printed out to the screen.
NOTE: Checking the correctness of a char and correcting it (if necessary) MUST be done in the
function with a call-by-reference fashion to the relevant cell of the 2D array. Every other functionality
MUST be done in the main function.
ΔΕΛΗΓ
function with a call-by-reference fashion to the relevant cell of the 2D array. Every other functionality
MUST be done in the main function.
Input
Output
44
7927
AbcX
D6F8
Cdbp
X
25
gYT9a
j71Xn
55
g__a
_7_X_
55
AFDHJ
0???x
Kwhy 1
S???E
KLO18
???_
_why_
???_
Transcribed Image Text:Assignment Write a program that reads a 2D array of chars, checks, and corrects each char within this array, and print out the corrected 2D array. First the program will read the row count (rowCount) and column count (columnCount) of the 2D array, both as int values. Then, the chars constituting the 2D array will be read on a row-by-row basis. After reading the 2D array, the program will check and correct each char within the 2D array according to the rules below. This process MUST be done by using a void function by sending the appropriate cell of the 2D array with a call-by-reference fashion. • If the row index is an even number, a char can only be a lowercase English value. • If the row index is an odd number, a char can only be ?, 7', or X'. • Any incorrect value MUST be changed into Finally, the checked and corrected 2D array will be printed out to the screen. NOTE: Checking the correctness of a char and correcting it (if necessary) MUST be done in the function with a call-by-reference fashion to the relevant cell of the 2D array. Every other functionality MUST be done in the main function. ΔΕΛΗΓ function with a call-by-reference fashion to the relevant cell of the 2D array. Every other functionality MUST be done in the main function. Input Output 44 7927 AbcX D6F8 Cdbp X 25 gYT9a j71Xn 55 g__a _7_X_ 55 AFDHJ 0???x Kwhy 1 S???E KLO18 ???_ _why_ ???_
Expert Solution
steps

Step by step

Solved in 3 steps with 4 images

Blurred answer
Knowledge Booster
Arrays
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage
Programming with Microsoft Visual Basic 2017
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning