I upload other video today
https://video.hardlimit.com/w/86T4wkWgMqmGY4YB5PcoBU
now introduce myself with #projectEuler platform, basically I resolved a simple problem just for know the platform.
I upload other video today
https://video.hardlimit.com/w/86T4wkWgMqmGY4YB5PcoBU
now introduce myself with #projectEuler platform, basically I resolved a simple problem just for know the platform.
I'm really liking #GoLang... done #ProjectEuler problem 24, got the answer on first attempt and it ran in less than 2 seconds which is not too shabby!
Initialised perms as [0 1 2 3 4 5 6 7 8 9]
Permuted to 3628800 items
Collapsed to 3628800 ints
Sorted
The millionth lexicographic permutation of the digits 0, 1, 2, 3, 4, 5, 6, 7, 8 and 9 is: <redacted>
real 0m1.370s
user 0m1.561s
sys 0m0.404s
A little bit of playing around in #Go with some of the #ProjectEuler problems I'd not done before... and I quite like it. Certainly seems easier to get my head around than #rust
Note: I'm not looking to start a Go vs Rust debate... just that I've played a little with both and have found Go easier to work with for the things I've tried.
Project Euler seems to be easy this week. A simple probability calculation for a deck of cards.
If you want the site's award for getting the latest puzzle, it can be done now. There's also another relatively easy one in the latest ten problems.
🧑💻 Write a script to “Find the sum of all the multiples of 3 or 5 below 1000” in O(1), i.e. constant time.
The solution is simple and elegant, try it out.
This problem is from #ProjectEuler.
#coding #math #python #haskell
Mein. Gott. #ProjectEuler
A few years ago, I had solved a lot of Project Euler problems #ProjectEuler problems in #Python. I even had a lot of very useful utility functions to make things more modular and easier.
After seriously starting to learn #Haskell sometime last year, I've been slowly translating that old code. I translated the utility functions as a way to learn the new language. I made a lot of progress this week on the problems themselves and I've realized how much better it is in Haskell.
Of course, a part of it is that I've changed as a programmer, but the old Python code looks ugly compared to what I'm now writing in Haskell. The functional paradigm with lazy evaluation seems to fit perfectly with the kind of problems on Project Euler.
My only "complaint" is that memoization is harder in Haskell. However, that's because I haven't spent any time figuring out how to do that well. It is not a language issue, but a me issue.
I've definitely decided that I'll be finishing my "solve substantial problems on Project Euler" goal in Haskell and not use Python for that anymore.
I just did 2*3*4*5*6**7*8*9*10 to see the result like a moron
I am sutdying #projectEuler on rust, *please* do not send spoilers or suggestions
The #ProjectEuler experience: You cannot even rely on formulas from Wikipedia. For real.
I dare you to solve just one #ProjectEuler today:
https://projecteuler.net/problem=836
(difficulty: 0-5% - for real, I swear)
Finished the first hundred challenges in #projecteuler. Now, the next 100.
@teotwaki thank you! I haven't done these in a while, so I'm definitely lacking in these type of events. I used to do the #ProjectEuler problems daily for years... 😅 But that was years ago. 🤣
My bet however, this time was mostly time to do it. I had to squeeze between family and work. So like an hour to 2 hours a day at most. Else it was past midnight the next shot. 🫠
I started doing #ProjectEuler again today, and I keep coming up with awful solutions that take like 10 minutes to compute...
But on the bright side, said insane compute time led me to dive into the Sieve of Eratosthenes algorithm and get it working in Python because finding primes is hard.
Proud of myself since I hate doing math usually!
Ich überlege ja, ob ich dieses Jahr wieder beim #AdventOfCode teilnehme oder ob ich stattdessen lieber mal wieder ein paar Probleme beim #ProjectEuler löse. An letzterem habe ich 2013 zum letzten Mal gearbeitet. Muss mal schauen, ob da irgendwo der Quellcode noch herumfliegt. Mein Fortschritt ist jedenfalls noch da 🙂. https://projecteuler.net
Solving Project Euler problem 1 in pure lambda calculus is not that hard:
https://gist.github.com/noughtmare/7397c8821a8e8b12ff88ab04c8696983
Project Euler 001
https://peertube.nz/videos/watch/9675d2fa-3f7c-4be5-a0b0-61f3aaa271f0
considerata "l'amicizia" di #crystallang e #ruby sto aggiungendo anche qualche scriptino in Ruby appunto.
Aggiornamento #projecteuler
Visto che siamo in 16(😢) a giocare con #crystallang, alla fine ho pensato di raccogliere le soluzioni in un repo su framagit!
Non che le mie soluzioni siano particolarmente originali ed esemplari ma, magari possono essere utili, chissà! Condividere inoltre potrebbe aiutarmi a trovare la spinta per andare avanti senza mollare subito 😂
Qualche soluzione è anche in C (volevo vedere se ricordavo qualcosina dopo molti anni 😅)
Iniziato Project Euler finalmente 🤣 (per ora con #crystallang )
Esiste troppa roba interessante 😅
Doing #projecteuler with #clojure has left me with an inability to write non-tailrecursive code.