I have a programming assignment focused on these functions due in a few days and you just taught me everything i need to know about random number generation for the assignment. Thank you so much!
And now you can ask: "Why do i need rand function?". Many simulations and scientific studies need to repeat the same set of random numbers. rand() will always do that if you don’t seed the random number generator.
Can you help me to create a random array using rand (seed) of 10,00,000 size for linear search to find time complexity, Sir. Pls help me to create the array using rand of that size.
The sequence of random numbers generated will be different on each run after using srand but is it possible to get a same number which was generated in previous run of the program as in a duplicate?
Could you share what you use to do screen recording and providing that yellow highlight? I have to record a video for my C class. Excellent explanation on the topic :)
I've used screen capture in OBS Studio for both Mac and Windows. Whether the cursor is highlighted or not is a setting in OBS. For Windows, I've also used VSDC, but after learning OBS, I don't think I'm going back.
What if you need a random number from 1 to 1 million, with a seed 179. The first iteration is 545994 but I can't get it. I'd like to know how to do this.
I want to create an array with different numbers 0 to 9 but I dont want same numbers in array. (for ex I dont want {0,2,3,6,2,0,1,4,3}) Can u guys help me please ?
//for c++ const short minValue = 1; //set to any number you want const short maxValue = 6; //set to any number you want srand(time(0)); int randomNumber = (rand() % (minValue - maxValue)) + 1; cout
Thanks for this helpful video! In my program RAND_MAX generated is 2147483647. Doe random_max depend on compiler since now int in most compilers is of 4 bytes?
I have a programming assignment focused on these functions due in a few days and you just taught me everything i need to know about random number generation for the assignment.
Thank you so much!
Best of luck!
Now, I also have the same type of assignment...
Wait I have same type of assignment too that's why I am here
Me having any study related problems
An Indian Guy on TH-cam: "Who's summoned me now?"
Thanks mate!
WoW...You explained from scratch..
Got a crystal clear idea.
Thank you sir..
You are most welcome
Thankyou so much for your efforts to explain it in much easier way... Great job!
Thanks
thank you very much, your explanations are very good and I finally understand how this function works!
Glad this video helped you :)
the way you explained the concept was super clear.
Thank you so much!!!!!!!!!
You're very welcome!
Finally, you made me understand that tricky little thing!!!!
Glad my video helped you
this is what we call full explanation .😍
Thank you so much 😀
Great explanation sir, thank you a lot
Btw congratulations for 100 comments, you truly deserve a lott
Pleasure 😀
this is so enlightening. you're a good teacher
thank you :)
Thank you for such a awesome video
You are so welcome!
A very clean and simple explanation for the topic. I have been struggling with this for some time now. But so glad to have found the video.
Glad it helped!
Thanks!!! I think i almost get it! I should watch the video one more time))))
Great!
Thank you very much it's straight to the point and very useful !!!
Glad this video helped you :)
Bro you are going to hit the sky high followers soon.
Amazing video
Thank you so much 😀
best way of explaining, thanks dude
Pleasure :)
your c++ and c courses are superb bro
Glad you think so!
awesome expalanation , thank u mr. anil shetty !!!
pleasure :)
Thank you really i followed all the your steps and it will be installed 🙏🏻❤️
Yup :)
And now you can ask: "Why do i need rand function?". Many simulations and
scientific studies need to repeat the same set of random numbers. rand() will always
do that if you don’t seed the random number generator.
Your explanation was really good.
Thanks to you I understood how the fucking function works.
damn You are the most amazing man on this planet! you explain effortlessly! Big big thanks
pleasure :)
Can you help me to create a random array using rand (seed) of 10,00,000 size for linear search to find time complexity, Sir.
Pls help me to create the array using rand of that size.
You're better than my professor...
Ha ha
Thanks :)
Just amazing bro thanks
Most welcome :)
brilliant explanation, thank you so much
You're very welcome!
Solid lesson. Thanks 🙏🏼
My pleasure!
This was really helpful, clear explanation
thank you :)
yout just helped me so much, thanks all
Glad I could help!
Great explanation
Thanks a lot
You're welcome!
This was the best explanation. Thank you so much sir.
You are most welcome
thank you so much!! this was really useful.
You're very welcome!
Excellent, thank you very much!
most welcome :)
YOU SAVED ME THANK YOU SO MUCH
Pleasure :)
Thank you for your clear and concise explanation!!
very good explanation!
Glad you think so!
Very cool video! Can't wait for the next part with range as parameter :D
CONGRATULATIONS ON THE VIDEO
thank you :)
thanks for helping me study final
You are most welcome
too many ads but it helped me understand !
I don’t think I have inserted many ads
Nowadays youtube plays 2 ads continuously
I will check it
Glad that my video helped you
I like video and I have hit the like button
thanks
Thank you so much sir...very well explained :)
Most welcome!
awesome logic man
Thank you
Greatly explained, thank you.
Pleasure
thanks for the explanation
You're welcome
The sequence of random numbers generated will be different on each run after using srand but is it possible to get a same number which was generated in previous run of the program as in a duplicate?
great teacher
Thank you! 😃
Could you share what you use to do screen recording and providing that yellow highlight? I have to record a video for my C class. Excellent explanation on the topic :)
I've used screen capture in OBS Studio for both Mac and Windows. Whether the cursor is highlighted or not is a setting in OBS. For Windows, I've also used VSDC, but after learning OBS, I don't think I'm going back.
Please teach random number generation by using Norma distribution
i will try to make a video :)
how to find the given dataset random number use, what type of algorithm is used?
Great explanation
Thanks a lot , you're the best bro
Pleasure :)
Cant you use a pointer to address to seed? Each compile should be different no?
Very much helpfull video sir
Thank you for this video💕It was really helpful!
Well explained thank you very much :D
You're welcome!
beautifully explained...
Thank you so much 🙂
Good
It was really helpful
Glad it helped
you are good
Thanks
Hi. I'll just ask, where can I find the random number generator compiler?
Thank you so much
You're most welcome
help me a lot really appreciate
Thanku so much sir
welcome :)
thanks alot 🥰
most welcome :)
can we save the random number in a variable so we create a varification process in which user verify the random number
yes you can do that :)
@@LearningLad I tried but [if()] function is not working when int userinput == rand()
Super well and good Sir
Thank you :)
What if you need a random number from 1 to 1 million, with a seed 179. The first iteration is 545994 but I can't get it.
I'd like to know how to do this.
Thank you
You're welcome
Thanks guy
Thanks bro
Welcome
How would you reset the count so that if I was to loop this function 5 times the random numbers don’t add up
Please how can i start by number negative .exp : -7 ----> 10
Awesome 😍😍
Thanks 🤗
can you explain about your channel logo?
give this man an oscar
can you tell how to generate random position for shapes in c I am really struggling with that thing
Awesome
thanks
I want to create an array with different numbers 0 to 9 but I dont want same numbers in array. (for ex I dont want {0,2,3,6,2,0,1,4,3}) Can u guys help me please ?
I think its not possible, what is possible is to take input from user
@@yesitsme6 I have solved it. Thank you :)
@@Ap-ui6kk Can u send me the code of how u do that? My tests comming
thanks
Welcome
very helpful
Glad you think so!
Thanks!!!!!
Welcome!
Sir the srand ask for which number the max number or the start number
If it ask for start number then how the rand() returns the number which less then srand value.
//for c++
const short minValue = 1; //set to any number you want
const short maxValue = 6; //set to any number you want
srand(time(0));
int randomNumber = (rand() % (minValue - maxValue)) + 1;
cout
Thanks for this helpful video! In my program RAND_MAX generated is 2147483647. Doe random_max depend on compiler since now int in most compilers is of 4 bytes?
Thx Legend!!
I want these function to execute only once each time it is called how to do that?
I've used seed and rand function in loop to generating random numbers but i got the same value from 1 loop.
nice
why does mine and your computer prints the same random number?
How to generate random alphabet
🔥🔥🔥🔥🔥🔥❤
thanks
indian guy carry
why null you say??
I think null puts the time in seconds from 1-1-1970 if u had to use some parameter then I wouldn't be random(the same problem)
Great explanation. Thank you
most welcome :)
Thank you so much, this was very helpful!
You're very welcome!
thank you
Pleasure 😃
thanks bro
Welcome
thanks brother
Welcome