小编Mur*_*ira的帖子

Cin不是在等待输入

这是该计划:

#include <iostream>
#include <string>
#include <stdlib.h>


using namespace std;

int main(){


string strKingdom = "";
bool conquered_me;//see if was conquered, was going to use this on other program and true = game over.
int gold;
int food;
int citizens;
int soldiers;



cout << endl <<"Name of kingdom: ";
cin >> strKingdom;
cout << endl << "were you conquered (true/false): ";
cin >> conquered_me;
cout << endl << "How many gold do you have?:";
cin>>gold;
cout << endl << "How …
Run Code Online (Sandbox Code Playgroud)

c++ cin

1
推荐指数
1
解决办法
1051
查看次数

标签 统计

c++ ×1

cin ×1