+ 1

# Popsicles java

Realice el desafío de popsicles y no entiendo porque la verificar en un caso me dice error, alguna ayuda? https://code.sololearn.com/cx6HMkLyjIqp/?ref=app

23rd Dec 2019, 6:45 PM
Cesar Estiven Mesa
7 ответов
0
I used popsicles%siblings==0 Instead of popsicle - sibling
23rd Dec 2019, 7:40 PM
HNNX 🐿
0
% (modulus) gives us the remainder when dividing two numbers Like 4%2 will give 0 (as 4 is divisible by 2) But 5%2 will give 1(as it is remainder) So in popsicle question if you can give all siblings then only you will distribute So numbers of popsicles should be divisible by number of children (remainder should be 0) Use popsicles%siblings==0
24th Dec 2019, 3:55 PM
Marvellous Person
- 1
Hola cesar que tal, pudiste resolver el ejercicio? Estoy igual que tu
29th Jan 2020, 3:24 PM
Diego Rangel
- 1
Si , era cambiar algo , mira https://www.sololearn.com/coach/3?ref=app
29th Jan 2020, 5:21 PM
Cesar Estiven Mesa
- 1
El link que mandaste me envía a el ejercicio, no puedo ver lo que escribiste
29th Jan 2020, 6:30 PM
Diego Rangel
- 2
Code works on my side, just input your numbers in separate lines like this: 7 12
23rd Dec 2019, 8:40 PM
HNNX 🐿
- 3
Yes, but, what is the diferrence to declare in other variable?
23rd Dec 2019, 8:00 PM
Cesar Estiven Mesa
Актуальное сегодня
Bug