Slučajni uzorak broja

/ Random (disambiguation) /

.

Randomness is the lack of pattern or predictability in events. A random sequence of events, symbols or steps has no order and does not follow an intelligible pattern or combination. Individual random events are by definition unpredictable, but in many cases the frequency of different outcomes over a large number of events is predictable.

.

#include <iostream>

#include <cstdlib>

#include <ctime>

using namespace std;

int main () {

srand (time(0));

for (int x = 1;  x<25; x++) {

cout << 1+(rand()%6) << endl;

}

}

Debugging Mode


Pratite diskusiju/Subscribe
Obaveštavaj/Notify

0 Comments / Komentara
Najstarije/Oldest
Najnovije/Newest Izglasano/Most Voted
Inline Feedbacks
View all comments