Given non negative number
b , output result of
a%b , can’t use
a = 10 b = 3 ans = "3 rem 1" ( string format)
a is a lot bigger than
b , how to optimize? I heard there is a method using binary search for this case, but not sure how to apply it?