+ 1

What does this % really do ...?

question

27th Jun 2017, 9:40 AM
Tafadzwa Manzunzu
Tafadzwa Manzunzu - avatar
5 Respostas
+ 2
That's a modulo operator, it returns the remainder of a division operation eg 4÷2=2 4%2=0
25th May 2018, 2:19 PM
Sedrick Takunda Nyanyiwa
Sedrick Takunda Nyanyiwa - avatar
+ 7
It is the modulo operator. m%n will return the remainder of m/n. E.g. 3%2 = 1 2%2 = 0 5%3 = 2
27th Jun 2017, 9:44 AM
Hatsy Rei
Hatsy Rei - avatar
+ 2
are you saying it only gives the remainder of a division operation
27th Jun 2017, 9:46 AM
Tafadzwa Manzunzu
Tafadzwa Manzunzu - avatar
+ 1
That is exactly what Hatsy is saying
27th Jun 2017, 10:01 AM
LordHill
LordHill - avatar
+ 1
calculate the reminder
27th Jun 2017, 10:04 AM
Hetbo.net
Hetbo.net - avatar