题解 | #明明的随机数#
明明的随机数
https://www.nowcoder.com/practice/3245215fffb84b7b81285493eae92ff0
#include <iostream> #include <vector> using namespace std; int main() { int n,t; vector<int> arr(501,0); cin >> n; for(int i =0; i < n; i++){ cin >> t; arr[t] = 1; } for(int i = 1;i <= 500; i++) if(arr[i]==1) cout << i <<endl; } // 64 位输出请用 printf("%lld")