I am wondering what does this line of code mean?
b = (gen_rand_uniform()>0.5)?1:0;
gren_rand_uniform()is a function for generating random 0 and 1 numbers. However, I do not understand the meaning of >0.5and 1:0.
I know this should be the main question, please bear with me.
Thanks!
Victor
source
share