#include <iostream>
#include <algorithm>
#include <ctime>
using std::cout;
using std::endl;
int main()
{
int arr[] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 };
std::srand(std::time(0));
std::random_shuffle(std::begin(arr), std::end(arr));
for (auto i : arr) {
cout << i << " ";
}
cout << endl;
}
/*
run:
6 2 5 9 4 1 8 0 7 3
*/