使用getch()代替scanf(), 因为scanf()的输入判断就是以换行为基础的
printf("F\n");改为print("F");就可以啦
供参考: https://bbs.csdn.net/topics/370122046