Jump to content

Maze generation: Difference between revisions

m
→‎{{header|Chapel}}: Minor cosmetic code change to Chapel maze output
(Added Chapel language implementation)
m (→‎{{header|Chapel}}: Minor cosmetic code change to Chapel maze output)
Line 2,191:
for row in maze.dim(0) {
for col in maze.dim(1) {
var cell =if maze[row, col].spaces[direction.N] then write("+ "); else write("+---");
if cell.spaces[direction.N] then write("+ "); else write("+---");
}
writeln("+");
for col in maze.dim(1) {
var cell =if maze[row, col].spaces[direction.W] then write(" "); else write("| ");
if cell.spaces[direction.W] then write(" "); else write("| ");
}
writeln("|");
12

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.