0

Print(pow (2,2,3)) ans is 1 how?

16th Apr 2020, 1:34 PM
Sai Deepika Kathiri
Sai Deepika Kathiri - avatar
3 Réponses
+ 3
Sai Deepika Kathiri , the third argument if present applies the modulo operation so (2**2)%3 => 1. You can read more here: https://docs.python.org/3.5/library/functions.html#pow
16th Apr 2020, 1:39 PM
TheWh¡teCat 🇧🇬
TheWh¡teCat 🇧🇬 - avatar
16th Apr 2020, 4:32 PM
Sai Deepika Kathiri
Sai Deepika Kathiri - avatar