Black Diamond Dynamic
Black Diamond Dynamic

Why my code printing a series of question marks?
Here's the code I use to read a file. It is a dynamic array, the code is supposed to display a matrix X and spaces, but it is just inside the question marks diamond black. I and J are initialized in the loop unbundling, the points of the maze in a matrix of r (lines) running through C (column) and I and J are variables. But here's code to enter a blank canvas file:: input (string infile) (ifstream InStream; InStream.open (infile.c_str (), ios:: in) if (InStream.fail ()) (Cost <<"The file is not good. Program fails.") Else (max_length = 100 int, char [Title max_length]; InStream.getline (title, max_length); InStream>> r>> C; maze = new char * [r] for (int i = 0; i
maze[i]=new char[C];
}
InStream.close();
}
for (Int i = 0; I <r, i + +) (for (int J = 0, J <C, J + +) (court <maze <[i] [j]) court <<endl;))
Do not you read the maze of file. You read the title, max_length, the number of rows (r) and the number of columns in (C). But you have never read any by DATA thereafter. Thus, each element in the labyrinth of memory of points assigned character C, which have not been initialized to anything. Is more data in the file to be read? If not, where is the definition of the labyrinth? When X and spaces come from? File? If yes, you need the code to read it and stores it in the maze.
Calendar of exhibitions Bridgeport Connecticut Beardsley Zoo, 1875 Noble Ave. Hours: 9-4 days. Tiny Adventurers Wednesday 10:30, 1 pm Admission $ 11, $ 9 ages 3 to 11 people aged.
![]() |
No items matching your keywords were found.
