someone help


#include <iostream>
#include <ctime>
#include <cstdlib>
#include <windows.h>
int end = 0;
int num;
char let;
using namespace std;
unsigned long stepInt = 0;
const int size = 40;
int arraybox[size][size]={177,177,177,177,177,177,177,177,177,177,177,177, 177,177,177,177,177,177,177,177,177,177,177,177,17 7,177,177,177,177,177,177,177,177,177,177,177,177, 177,177,177,
177, 0,0,0,177,0,0,0,0,0,0,0,177,0,0,0,177,0,0,0,177,0, 0,0,0,0,177,0,0,0,177,0,0,0,0,0,0,0,0,177,
177,177,177,0,0,0,177,177,177,177,177,0,0,0,177,0, 177,0,177,0,177,0,177,177,177,177,177,0,177,0,177, 0,177,177,177,177,177,177,0,177,
177,0,0,0,177,0,177,0,0,0,177,177,177,177,177,0,0, 0,177,0,177,0,177,0,0,0,177,0,177,0,0,0,177,0,0,0, 0,177,0,177,
177,0,177,177,0,0,0,0,177,0,177,0,0,0,177,177,177, 177,177,0,177,0,0,0,177,0,177,0,177,177,177,177,17 7,0,177,0,0,177,0,177,
177,0,0,177,0,177,177,177,177,0,0,0,177,0,0,177,0, 177,0,0,177,0,177,177,0,0,177,0,0,0,0,0,177,0,177, 0,0,177,0,177,
177,177,177,177,0,0,0,0,177,177,177,177,177,177,0, 177,0,0,0,177,177,0,177,0,0,177,177,177,177,177,17 7,0,177,0,177,0,177,177,0,177,
177,0,0,0,0,177,177,0,0,0,0,0,0,177,0,177,0,177,17 7,177,0,0,177,0,177,177,0,0,0,177,177,0,177,0,177, 0,0,0,0,177,
177,0,177,177,177,177,177,177,177,177,177,177,0,17 7,177,177,177,177,177,0,0,177,177,0,177,0,0,177,0, 177,0,0,177,0,177,177,177,177,177,177,
177,0,177,0,0,0,0,0,0,0,0,177,0,177,0,0,0,0,177,0, 177,177,0,0,177,0,177,177,0,177,0,177,177,0,0,0,0, 0,0,177,
177,0,177,0,177,177,177,177,177,177,0,177,0,177,0, 177,177,0,177,0,177,0,0,177,177,0,177,0,0,177,0,0, 177,0,177,177,177,177,0,177,
177,0,177,0,177,0,0,0,0,177,0,177,0,177,0,0,177,0, 177,0,177,0,177,177,0,0,177,0,177,177,177,0,177,0, 177,0,0,0,0,177,
177,0,177,0,177,0,177,177,0,177,0,177,0,177,177,0, 177,0,177,0,177,0,177,0,0,177,177,0,0,177,0,0,177, 0,177,0,177,177,177,177,
177,0,177,0,177,0,0,177,0,177,0,177,0,0,0,0,177,0, 0,0,177,0,177,0,177,177,177,177,0,177,0,177,177,0, 177,0,0,0,0,177,
177,0,177,0,177,177,0,177,0,177,0,177,0,177,177,17 7,177,177,177,177,177,0,177,0,177,0,0,0,0,177,0,0, 177,0,177,177,177,177,0,177,
177,0,177,0,0,0,0,177,0,177,0,177,0,0,0,0,0,177,0, 0,0,0,177,0,177,0,177,177,177,177,177,0,177,0,177, 0,0,0,0,177,
177,0,177,177,177,177,177,177,0,177,0,177,177,177, 177,177,0,177,0,177,177,177,177,0,177,0,177,0,0,0, 177,0,177,0,177,0,177,177,177,177,
177,0,0,0,0,0,0,0,0,177,0,177,0,0,0,0,0,177,0,0,0, 0,0,0,177,0,0,0,177,0,0,0,177,0,177,0,0,0,0,177,
177,177,177,177,177,177,177,177,177,177,0,177,0,17 7,177,177,177,177,177,177,177,177,177,177,177,177, 177,177,177,177,177,177,177,177,177,177,177,177,0, 177,
177,0,0,0,0,0,0,0,0,0,0,177,0,177,0,0,0,177,0,0,0, 0,0,0,0,177,0,0,0,0,0,0,0,177,0,0,0,177,0,177,
177,0,177,177,177,177,177,177,177,177,177,177,0,17 7,0,177,0,0,0,177,177,177,177,177,0,177,0,177,177, 177,177,177,0,177,0,177,0,177,0,177,
177,0,177,0,0,0,0,0,0,0,0,177,0,177,0,177,177,177, 177,177,0,0,0,0,0,177,0,177,0,0,0,177,0,177,0,177, 0,0,0,177,
177,0,177,0,177,177,177,177,177,177,0,177,0,177,0, 0,0,177,0,0,0,177,177,177,177,177,0,177,0,177,0,17 7,0,177,0,177,177,177,177,177,
177,0,177,0,177,0,0,0,0,177,0,177,0,177,177,177,0, 177,0,177,177,177,0,0,0,177,0,0,0,177,0,177,0,0,0, 0,0,0,0,177,
177,0,0,0,177,0,177,177,0,177,0,177,0,0,0,0,0,177, 0,0,0,0,0,177,0,177,177,177,177,177,177,177,177,17 7,177,177,177,177,0,177,
177,177,177,177,177,0,177,177,0,177,0,177,177,177, 177,177,177,177,177,177,177,177,177,177,0,0,0,0,0, 177,0,0,0,0,0,0,0,177,0,177,
177,0,0,0,0,0,177,177,0,177,0,177,0,0,0,177,0,0,0, 0,0,0,0,177,177,177,177,177,0,177,0,177,177,177,17 7,177,0,177,0,177,
177,0,177,177,177,177,177,177,0,177,0,177,0,177,0, 177,0,177,177,177,177,177,0,0,0,0,0,177,0,177,0,17 7,0,0,0,177,0,177,0,177,
177,0,0,177,0,0,0,177,0,0,0,177,0,177,0,177,0,177, 0,0,0,177,177,177,177,177,0,177,0,177,0,177,0,177, 0,0,0,177,0,177,
177,177,0,177,0,177,0,177,177,177,177,177,0,177,0, 177,0,177,0,177,0,177,0,0,0,177,0,177,0,177,0,177, 0,177,177,177,177,177,0,177,
177,0,0,177,0,177,0,177,0,0,0,0,0,177,0,177,0,0,0, 177,0,177,0,177,0,0,0,0,0,177,0,177,0,0,0,0,0,0,0, 177,
177,0,177,177,0,177,0,177,0,177,177,177,177,177,0, 177,177,177,177,177,0,177,0,177,177,177,177,177,17 7,177,0,177,177,177,177,177,177,177,177,177,
177,0,0,177,0,177,0,177,0,177,0,0,0,0,0,177,0,0,0, 177,0,177,0,0,0,0,0,0,0,177,0,0,0,0,0,0,0,0,0,177,
177,177,0,177,0,177,0,177,0,177,0,177,177,177,177, 177,0,177,0,177,0,177,177,177,177,177,177,177,0,17 7,177,177,177,177,177,177,177,177,0,177,
177,0,0,177,0,177,0,177,0,177,0,177,0,0,0,177,0,17 7,0,177,0,0,0,177,0,0,0,177,0,177,0,0,0,0,0,177,0, 0,0,177,
177,0,177,177,0,177,0,177,0,177,0,177,0,177,0,177, 0,177,0,177,177,177,0,177,0,177,0,177,0,177,0,177, 177,177,0,177,0,177,177,177,
177,0,177,0,0,177,0,177,0,177,0,177,0,177,0,177,0, 177,0,0,0,0,0,177,0,177,0,0,0,177,0,0,0,177,0,177, 0,0,0,177,
177,0,177,0,177,177,0,177,0,177,0,177,0,177,0,177, 177,177,177,177,177,177,177,177,177,177,177,177,17 7,177,177,177,0,177,0,177,177,177,177,177,
177,0,0,0,177,177,0,0,0,177,0,0,0,177,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,0,0,177,0,0,0,0, 4,177,
177,177,177,177,177,177,177,177,177,177,177,177,17 7,177,177,177,177,177,177,177,177,177,177,177,177, 177,177,177,177,177,177,177,177,177,177,177,177,17 7,177,177};
int r = 1, c = 1;
void print(void);
void move(void);

int main()
{
int yo=1;


for (int i = 0; i < size + 1; i++) {
arraybox[i][0] =177;
arraybox[i][size-1] = 177;
arraybox[0][i] = 177;
arraybox[size-1][i] = 177;
}

print();


while (end != 1){
cout<<"\nw = up , a = left, s = down, d = right\n";
cin>>let;
num = static_cast<int>(let);
move();
print();
}

cout << endl << "Steps: " << stepInt << endl;
cin>>yo;

return 0;

}

void print()
{

for (int l = 0; l < size; l++) {
cout << endl;
for(int g = 0; g < size; g++)
cout<<static_cast<char>(arraybox[ l ] [g]);

}
}

void move() // just makes sure you cant run into walls
{


while (end != 1) {



if ( let == 'a' && arraybox[r][c-1] != 177 ) {//left

c = c - 1;
arraybox[r][c] = 27;
stepInt += 1;
}
else if ( let == 'd' && arraybox[r][c+1] != 177 ) {//right

c = c + 1;
arraybox[r][c] = 26;
stepInt += 1;
}
else if ( let == 'w' && arraybox[r-1][c] != 177 ) {//up

r = r - 1;
arraybox[r][c] = 24;
stepInt += 1;
}
else if ( let == 's' && arraybox[r+1][c] != 177 ) {//down

r = r + 1;
arraybox[r][c] = 25;
stepInt += 1;
}

if (r == size-2 && c == size-2) {
end = 1;
cout << endl << endl << endl << endl;
arraybox[r][c] = 4;
}


}
}

/*void walls()
{
int randR, randH, done = 0;

srand(time(0));

while (done != size / 1 + rand() % 4) {

randR = 1 + rand() % size - 1;
randH = 1 + rand() % size - 1;


if ( arraybox[randR][randH] != 177 ||
arraybox[randR-1][randH] != 177 ||
arraybox[randR+1][randH] != 177 ||
arraybox[randR][randH+1] != 177 ||
arraybox[randR][randH-1] != 177 ||
arraybox[randR+1][randH+1] != 177 ||
arraybox[randR-1][randH-1] != 177) {
arraybox[randR][randH] = 177;
arraybox[randR-1][randH] = 177;
arraybox[randR+1][randH] = 177;
arraybox[randR-1][randH-1] = 177;
arraybox[randR+1][randH+1] = 177;
arraybox[randR][randH+1] = 177;
arraybox[randR+1][randH-1] = 177;
done += 1;
}
}
}
*/