We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

General Discussions

Discuss any topics that are not product-specific here.

Euleryx Project 1 - Multiples of 3 or 5

Pilsner
13 - Pulsar

Euleryx Problem 1 - Multiples of 3 or 5

 

Pilsner_1-1753967002059.png

 

Here's my full workflow and Answer:

Spoiler
Pilsner_2-1753967021472.png

 

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! 

Pilsner_3-1753967266803.png

 

 

 

Here's how I tackled this problem:

 

  1. I began by creating two lists, one list containing all the multiples of 3, and the other list containing all the multiples of 5. I found the Generate Rows tool to be ideal for this task.

    Pilsner_6-1753967422431.png

     

  2. Using both the Union and the Unique tool, I created a list of all the distinct multiples of 3 or 5 (below 1000).

    Pilsner_7-1753967429133.png

     



  3. Finally, to sum the column, I used the Summarise tool.

    Pilsner_8-1753967459220.png

     

  4. Submit your answer to the Project Euler website. 

Pilsner_9-1753967466986.png

 

 

Congratulations, you’ve finished your first Project Euler challenge! Looking forward to seeing you all this time next week for Problem 2.

 

 

DoneImDoneGIF.gif



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.

 

 

 

 

28 REPLIES 28
Pilsner
13 - Pulsar

Our favourite solution will get a shout-out in next week's post!

BS_THE_ANALYST
15 - Aurora
15 - Aurora

Right, I'll go first:


Solution:

Spoiler
Not one for tool golf normally (skill issue on my side, I appreciate tool golf from the sidelines) but it seemed fitting 😈
Screenshot 2025-07-31 150153.png

 Looking forward to seeing some tricks that folks use here! I'm a sucker for a new function 🥴🤌🤣😈

All the best,
BS

LinkedIN

Bulien
TheOC
16 - Nebula
16 - Nebula

Similar to @BS_THE_ANALYST ,
I found a 3 tool solution:

Spoiler
TheOC_0-1753970977601.png

The mod function is really useful when I can remember it exists 😅

Nice challenge, looking forward to the next!

 

Cheers,
TheOC
Connect with me:
LinkedIn Bulien
Towers
11 - Bolide

Very excited for this! Im terrible with maths so hopefully this series helps me out big time 😅.

Spoiler
Opted for using a tile tool just to be a little different.
Screenshot 2025-07-31 151339.png
TheOC
16 - Nebula
16 - Nebula

Playing toolgolf...

Spoiler
I found a way to make it 2 tools.
TheOC_0-1753971648068.png

 


It's awful. Please do not replicate on anything practical:
TheOC_0-1753971416090.png



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!

Cheers,
TheOC
Connect with me:
LinkedIn Bulien
BS_THE_ANALYST
15 - Aurora
15 - Aurora

@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 🥴🤣

All the best,
BS

LinkedIN

Bulien
Pilsner
13 - Pulsar

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:

Spoiler
Ill just say one word, series. If that doesn't mean anything yet then don't worry, the explanation is already on its way. As "series" are so powerful they deserve their own post, we will cover them in detail on Problem 6.

Pilsner_0-1753972829548.png

 



TheOC
16 - Nebula
16 - Nebula

@Pilsner 
Literally my reaction opening that workflow

Cheers,
TheOC
Connect with me:
LinkedIn Bulien
aiahwieder
9 - Comet

Ooooooh, a new code challenge mashup, I love!

 

Here's my solution . . .

 

Spoiler
Starring my new best friend, Modulo!
Labels
Top Solution Authors