In SCAN Algorithm, the disk arm(head) starts at one end of the disk and moves toward the other end servicing requests as it reaches each cylinder it gets to the other end of the disk. At the other end direction of the head movement is reversed and servicing continues.
For the given problem, first the arm will move towards 99 and reverses back to Zero(0) as follows:
50->52->61->87>95->99->47->44->25->20->4.
Arm movements required to go from 50 to 52 = 2
Arm movements required to go from 52 to 61 = 9
Arm movements required to go from 61 to 87 = 26
Arm movements required to go from 87 to 95 = 8
Arm movements required to go from 95 to 99 = 4
Arm movements required to go from 95 to 47 = 52
Arm movements required to go from 47 to 44 = 3
Arm movements required to go from 44 to 25 = 19
Arm movements required to go from 25 to 20 = 5
Arm movements required to go from 20 to 4 = 16
Total head movements = 2+9+26+8+4+52+3+19+5+16 = 144