1 votes 1 votes ankit_thawal asked Jan 19, 2018 ankit_thawal 272 views answer comment Share Follow See all 5 Comments See all 5 5 Comments reply Show 2 previous comments Akshay Koli 4 commented Jan 20, 2018 reply Follow Share Yes none of the option is correct, output is- 1 -1 1 -1 2 0 votes 0 votes ankit_thawal commented Jan 20, 2018 reply Follow Share @Akshy Koli,@MiNiPanda How come the answer is 1 -1 1 -1 2? -5%-2=1 ? Isn't it? 0 votes 0 votes MiNiPanda commented Jan 20, 2018 reply Follow Share While doing this type, I do like :- Keep the quotient and remainder same Q= 2 and R =1 Now while adding signs to them we face difficulty.. Dividend = Q*divisor +R Dividend and Divisor are already provided so you cannot change them. So manipulate the Q and R so that the sign of LHS and rhs match. Here, -5 = -2(Q) + R which means rhs has to be -ve. -2 can't be multipled with -ve Q otherwise it would become +ve. So -2(-2) +R=-5 => R= -5+4=-1 However for other values it might be some different sign..so just try to change accordingly.. 1 votes 1 votes Please log in or register to add a comment.