#include <iostream>
#include <vector>
#include <algorithm>
#include <random>
using namespace std;
int main() {
    int n;
    cout << "请输入数字的个数 n: ";
    cin >> n;

    vector<int> numbers(n);
    cout << "请输入 " << n << " 个数字: ";
    for (int i = 0; i < n; ++i) {
        cin >> numbers[i];
    }

    // 使用随机设备生成随机数种子
    random_device rd;
    mt19937 g(rd());

    // 随机打乱数组
    shuffle(numbers.begin(), numbers.end(), g);

    // 输出打乱后的数组
    cout << "打乱后的数字序列为: ";
    for (int num : numbers) {
        cout << num << " ";
    }
	cout << endl;

    return 0;
}