Lang:G++
Edit12345678910111213141516171819202122232425262728293031#include <iostream>#include <cstring>using namespace std;int num[4];int num_now[4];int used[4];int ops[3];int opType[6] = {0, 1, 2, 3, 4, 5};//+, -, *, /, 反-, 反/double cal(double one, double two, int op){if(op == 0){return one + two;}else if(op == 1){return one - two;}else if(op == 2){return one * two;}else if(op == 3){if(two == 0) return 20000;return one / two;}