11 Answers
New AnswerI've found that the output of operation with both Forward Slash ' / ' and Modulo ' % ' have the same function which will produce floats. But why they are different? I still don't get the meaning. Somebody please help me to find out the answer
9/16/2018 5:55:15 PM
MTMA11 Answers
New Answerforward' / ' will give the quotient of operation modulo will give the reminder of operation for example 10/2 = 5 10%2=0(gives reminder)
Forward slash(/) gives the answer in float, while modulo(%) divides and gives the remainder.
To determine the quotient and remainder of a division, use the floor division and modulo operators, respectively. Floor division is done using two forward slashes. The modulo operator is carried out with a percent symbol (%).
Hi frnd one equvation 25%3: 25 dividing 3 for 6*4= 24 Also 25-24=1 The remaining for 1 This remaining is 1for answer the question and this modulus ok Another slash '/' Single slash is dividing ok An double slash is 20//6 6*3=18 20/6=3 20/6=3 3+3=6 6/3=3 Answer is 3
Sololearn Inc.
535 Mission Street, Suite 1591Send us a message