When passing r showing wrong output

for given sample case for r its printing ract too idk why its printing that please help