Question: This method prints out the maze in a nice, readable format using the blocked, visited, player, start, and goal fields. You can see a sample
This method prints out the maze in a nice, readable format using the blocked, visited, player, start, and goal fields.
You can see a sample output in the easyoutput.txt file in the data directory.
You will need to print the border like you see in the sample output. The corners are asterisks, the top is dashes, and the sides are pipes vertical bars
A spot with an is blocked.
A spot with a space is open.
The starting location is an
The goal location is a G
The player's location is an a
Any visited spot is a period.
The printMaze test should pass when you are done.
Hints
Use nested loops to go over the blocked array.
Use if statements to choose which character to print.
Consider where you need to print newlines.
Character priority:
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
