代码如下: # include vector # include iostream # include set using namespace std; int main(int argc, char * argv[]) { vectorint v; //找一些数据来测试 for (int i = 0; i 50; i++) v.push_back(rand() % 25); for (int i = 0; i 50; i++) { cout v[i] '\t'; if ((i + 1) % 10 == 0) cout endl; } cout endl; ////////////////////////////////////////////////////////////...[ 查看全文 ]