I'm just slightly confused about line 30, so would I just skip line 40.
Could someone show me how to do the question please because I don't understand the markscheme.
x Turn on thread page Beta
d1 algorithm watch
- Thread Starter
- 25-12-2014 18:53
- 25-12-2014 18:57
line 30 tests for evenness.. if A is even then skip line 40
- 25-12-2014 18:59
i don't do D1 but I think it means if the result of INT(A/2) is the same as A/2 (without INT) then go to line 50. so for example, since A = 20, INT(20/2) = 10 which is the same as 20/2 = 10, it will go to line 50. but if A was not an integer divisible by 2 then INT(A/2) would return a different value than A/2 (e.g. if A = 7, INT(7/2) = 3 but 7/2 = 3.5).Last edited by ltsmith; 25-12-2014 at 19:01.