0

What is #include<cstdlib> used for? What is the reason for using this when using rand or srand function?

I am new at c++ and learning the scientific and mathematics implications of it.

15th Nov 2019, 5:47 PM
Kumar Ashish
Kumar Ashish - avatar
1 Réponse
0
You need to import libraries to use certain functions as every functionality is not implemented in <iostream>. To use "srand" and "rand" you have to import/include "cstdlib" because it is defined in that library.
2nd Mar 2025, 1:26 PM
Nabir14
Nabir14 - avatar