How to use random numbers in Linux and C ++?
I found code that I would like to use, it has a line
srand((unsigned)time(0));
but gcc says
board.cpp: 94: 24: error: "time has not been announced in this area
I have included the following files
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <vector>
#include <algorithm>
source
share