My ATM project wont work

I got a big problem
so I did a project called ATM
and watch youtube to do the basic of it
then I upgraded it and it worked (first version)
but because it got a few bug, I upgraded it again and fix the error.
but now its not working anymore. It suppose to ask for accout number and see if it valid or not. If not then redo but if yes then it should show a menu and lemme do different stuff. But now when it asks me for my account number and when I type my account number in, the program just stop instead of showing the menu and contineau working.
After a week, I still cant find out what went wrong.
can anyone please check what’s wrong for me?

Hi,

You need to give us a bit more info to help you in debugging.

For example you have your hypothesis:

But now when it asks me for my account number and when I type my account number in, the program just stop instead of showing the menu and contineau working.

Some important things to consider:

  • what functions in your program are related to this problem?
  • what input do those functions take?
  • have you tested the functions outside of this problem?
  • what other things have you tried?

Linking your whole file is nice, but also linking the relevant functions related to the bullet points above will help a ton.

So… im not even sure what function related to this problem but I think its the inputcheck function which I think at line 33. It might have something to do with cin.clear() and cin.ignore(). I am not sure. So the input will be the account and the function should check if it valid. I used some trick to return 2 value and It will return the account and the valid. I tried to do some change but I dont think it’s any better. I tried a lot of thing that I dont even remember. Please help me with this. Thank you in advance.