Back to problems

Maze Solver: Print a Maze With Empty Cells Marked

Algorithm · Meta · Easy

Problem: Render a Maze (show empty cells as *) You receive an R x C two-dimensional character maze named grid. A position may contain a wall (#), an open blank character (' '), or another character that can also be traversed. Write a maze-display routine that prints the maze unchanged except that every blank character (' ') is displayed as *. Characters other than blanks must be emitted exactly as they appear. Input The first line provides two integers: R and C. The…

Checking your access…