Home > Back-end >  Why can't run 2013 vs void problem
Why can't run 2013 vs void problem

Time:09-23

#include
# pragma warning (4996) disable:
Int main ()
{
//to Hanoi function declaration
Void Hanoi (int n, char one, char two, char three);
int m;
Printf (" input the number of diskes: ");
The scanf (" % d ", & amp; M);
Printf (" The step to move % d diskes: \ n ", m);
Hanoi (m, 'A', 'B', 'C');
}

//definition Hanoi function: n dish from one with two seats, moved to the three cities
Void Hanoi (int n, char one, char two, char three)

{
Void move (char x, char y);//to move function declaration
If (n==1)
Move (one, three);
The else
{
Hanoi (n - 1, one, three, two);
Move (one, three);
Hanoi (n - 1, two, one, three);
}
}

Void move (char x, char y)//
move functions are defined{
Printf (" % c - & gt; % c \ n ", x, y);
}

CodePudding user response:

I function declarations to go outside in the main
  • Related