In this case use %d to get -9 because if we use %d it signed int as there we have -4 and -5 the desired answer will be printed