They are in red.
Code:Lets say for exapmle : min = 6 and max = 8 Lets assume RAND_MAX=13 so we get // i = 6 + 2 * {0,13}/13; i = 6 + ( 2 * {0,13} ) /13; for rand>= 0 && rand<=6 we get i = 6 for rand>= 7 && rand<=12 we get i = 7 for rand>= 13 && rand<=13 we get i = 8