#include<iostream>
class Hanoi {
public:
Hanoi();
void solve(int, char, char, char);
};
Hanoi :: Hanoi() {
}
void Hanoi :: solve(int n, char from, char use, char to) {
if (n > 0) {
solve(n-1, from, use, to);
cout << "Move disk " << n << " from " << from << " to " << to << endl;
solve(n-1, use, to, from);
}
}
int main(void) {
Hanoi h;
int N;
cout << "Enter number of disks : " << endl;
cin >> N;
h.solve(N,'A','B','C');
cin >> N;
}