Problem 52532. Easy Sequences 5: Project Euler Problem 1 - Again!
Solution Stats
Problem Comments
-
1 Comment
It's not exactly Euler Problem 1 since we need to calculate the lcm between the two numbers, but it's ok.
Solution Comments
-
1 Comment
I got Tests 1 and 3 correct. I've made sure the MATLAB precision is no longer a factor, but somehow the other 2 were still a fair way off the correct answer.
-
2 Comments
Hi,
Your solution is almost correct but your removing duplicates at multiples of the product of mult1 & mult2. You may actually find duplicates at multiples of less than that product.
Oops! I knew I was forgetting something! Thanks for the tip Ramon.
Problem Recent Solvers7
Suggested Problems
-
Sum all integers from 1 to 2^n
12220 Solvers
-
What is the distance from point P(x,y) to the line Ax + By + C = 0?
339 Solvers
-
Change the sign of even index entries of the reversed vector
422 Solvers
-
Return fibonacci sequence do not use loop and condition version 2
43 Solvers
-
3205 Solvers
More from this Author90
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!