Program to find remainder without using modulo or % operator | This function returns remainder of num / divisor without using % ( modulo ) operator ; Driver Code
< ? php function getRemainder ( $ num , $ divisor ) { $ t = ( $ num - $ divisor * ( int ) ( $ num / $ divisor ) ) ; return $ t ; } echo getRemainder ( 100 , 7 ) ; ? >