Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Code Challenge: Snacky Friends, a donkey, and Apples
#3
With the code I wrote, the first possible solution for number of apples bought: 79

Friend 3 ate a total of 18 apples.
Friend 2 ate a total of 24 apples.
Friend 1 ate a total of 33 apples.

The donkey ate 4 apples.

Friend 1 is a pig.

I'm not entirely convinced I got it right, so I look forward to confirmation one way or the other via other approaches.
Reply


Messages In This Thread
RE: Code Challenge: Snacky Friends, a donkey, and Apples - by CharlieJV - 08-04-2024, 04:15 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Challenge for you... eoredson 61 13,234 01-11-2026, 03:48 AM
Last Post: bplus
  Correcting the code Chris 15 3,310 10-28-2023, 09:48 PM
Last Post: SMcNeill
  Summer LASER Challenge TerryRitchie 42 9,147 07-30-2023, 06:57 PM
Last Post: bplus

Forum Jump:


Users browsing this thread: 1 Guest(s)