Euleryx Problem 1 - Multiples of 3 or 5
Here's my full workflow and Answer:
Answer: 233168
Method:
With this being the first problem in the series, we’re kicking things off with a relatively simple challenge. Typically, the challenges do get harder (which will likely become clear by Problem 3), but rest assured, we will do our best to explain what we’ve done.
That being said, the solution below is just one way to solve this problem; there are many different available routes!
Here's how I tackled this problem:
Congratulations, you’ve finished your first Project Euler challenge! Looking forward to seeing you all this time next week for Problem 2.
Summary
In just 3 simple steps, we have already found an answer to the first Project Euler challenge. Please feel free to share your solutions below. I hope you enjoyed the first challenge.
Our favourite solution will get a shout-out in next week's post!
Similar to @BS_THE_ANALYST ,
I found a 3 tool solution:
The mod function is really useful when I can remember it exists 😅
Nice challenge, looking forward to the next!
Very excited for this! Im terrible with maths so hopefully this series helps me out big time 😅.
Playing toolgolf...
The filtering can technically be done within the generate rows loop expression. It's so unreadable, and I'd suggest that it's just not a performant solution, but hey - reduced the tool count by 1!
@TheOC I love that you called the second solution "Dangerous Edition" 🤣.
Great idea with the looping expression trick. I considered this but I skipped it as I thought the loop would terminate if I was on a number that wasn't a multiple. Feeling jealous and unworthy at the moment, no biggie 🥴🤣
Loving some of the solutions already.
@TheOC, you've got me with the tool golf idea. Was saving the explanation for Problem 6, but I guess we can have a mini spoiler now:
One tool solution:
@Pilsner Literally my reaction opening that workflow
Ooooooh, a new code challenge mashup, I love!
Here's my solution . . .