Scusa, ma visto che usi il c++ non ti conviene usare cin e cout?
Ciao