Answer the question
In order to leave comments, you need to log in
What are the plugins, widgets, modules for Telegram to install on the site?
Hello!
Who knows what plugins, modules or widgets exist for Telegram?
I want to link a Telegram channel on my website.
Answer the question
In order to leave comments, you need to log in
I'll try to explain the way to understand the overflow problem.
double temp = random(a, b);
Substitute here yourself different values (for example 0 5 or -5 and 3) think about what possible results the function can return (maximum and minimum). Add the boundary results to b (you have temp + b ) remember what is the maximum number of elements you selected.
2. Still reset the allocated memory block. You can use your hands in a loop, or you can use www.cplusplus.com/reference/cstdlib/calloc for example (it's more difficult to get confused with the parameters there).
3. Your result function expects the number of iterations, a, b and you pass it a, b, the number of iterations. As a result, all values fall into the wrong place. Perhaps the compiler tried to tell you about this with vornigns - read them, they are your friends.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question