用scanf是不存在这个问题的。但是scanf_s,对于字符和字符串输入,要多加1个缓冲区大小的参数,如下: scanf_s("%c", &o, 1);
测试通过。Please enter an operator:+Please enter two numbers:14 1.00+ 4.00= 5.00Process returned 0 (0x0) execution time : 4.637 sPress any key to continue.说一下你的输入?