I want to know how I can, given a list, shuffle the order of the elements within it. The type structure of the list I want to shuffle is as follows.
struct exemplo {
int I;
int O;
int V;
struct exemplo *prox;
}
I want to know how I can, given a list, shuffle the order of the elements within it. The type structure of the list I want to shuffle is as follows.
struct exemplo {
int I;
int O;
int V;
struct exemplo *prox;
}
Probably using the rand () function that generates a number from 1 to 3, then with those numbers you change the elements you have in that random order list