sir i wrote this code without using the cumulative sum approach but when i input a=1 and b=10 then i get answer as 5 not as 4. same is the case when i input a=11, b=20.
i am getting an answer in which 1 is added in excess. why is it so?? here is the code i wrote -
please somebody look into this and tell me what am i doing wrong???
