+ 1

Hii I just solved the popsicles coding challenge but there's something I don't understand. Can someone pls help me?

This code didn't work: siblings = int(input()) popsicles = int(input()) #your code goes here if popsicles%siblings=0: print("give away") else: print ("eat them yourself") but this did: siblings = int(input()) popsicles = int(input()) #your code goes here if popsicles%siblings>0: print("eat them yourself") else: print("give away") Why didn't the first code work?

3rd May 2023, 5:36 PM
Rainnn
Rainnn - avatar
3 Respostas
+ 10
"=" is assignment, "==" is the equality operator.
3rd May 2023, 5:46 PM
Lisa
Lisa - avatar
0
Ohh ok thank you!
4th May 2023, 5:03 AM
Rainnn
Rainnn - avatar
0
Lets see the source code
4th May 2023, 9:13 AM
Klufio