Help ramu code doubt


what is wrong with this code??
the answer in coming one less than what it should come