yogsototh
But quite surprisingly, when later during my Ph.D. part of my time was dedicated to give exercises to students. And we used logo instead of the more usual programming languages. And I think it really helped them to really internalise programming a lot better. Typically, the latest exercices introduced recursion which is immediately visible as fractals.
HIDETURTLE
PENUP
SETXY -200 0
RIGHT 90
PENDOWN
to dragon :degree :size
setpensize 1
if :size>5 [setpensize 2]
if :size>10 [setpensize 3]
if :size>20 [setpensize 4]
if :size>40 [setpensize 5]
ifelse :degree=0 [
fd :size
][
left 45 dragon (:degree-1) (size/4)
right 90 dragon (:degree-1) (size/2)
left 90 dragon (:degree-1) (size/4)
right 45
]
end
dragon 6 3000
if you want to give a try :)[#1]: https://her.esy.fun/posts/0031-how-i-protect-my-forgejo-inst...
I configure my local repositories to push on both Github and my forgejo instance. I am not using the CI much for my private projects (local tests are enough in my case).
What side for python? Haskell? Idris? Clean? C? K?...
white/dark side is too much of a simplification to me.
Programming language equilibrium is a very complex subject and fascinating one.
After years of experimenting with many of them, it is all a matter of context of usage, personal preferences, objectives, etc.. there is no such thing as "the best programming language ever", neither "best for light side programming" nor "best for dark side programming".
Similarly, there is no such things as: Light side/Dark side in artistic painting. There are tons of paints some are clearly greater than others, but there is no such thing as "the best painting most beautiful for everyone seeing this paint comparatively to any pain".
[^Malbolge]: https://en.wikipedia.org/wiki/Malbolge
[^Clean]: https://en.wikipedia.org/wiki/Clean_(programming_language)
[^K]: https://en.wikipedia.org/wiki/K_(programming_language)
Ask AI to build something. By default it will use python. Sometimes js or typescript.
Ask then to do the same thing in Clojure. The result is generally an order of magnitude better. Shorter, easier to read for both humans and llm. Easier to adapt to changes.
So I guess this ratio about easy vs difficult question should be a parameter in such spaced repetition algorithms.
I think it would be nice for people to take a look at them:
- Aniara (2018)
- High Life (2018)
and maybe in a less artistic view:
- Powers of Ten (1977) yt: https://www.youtube.com/watch?v=0fKBhvDjuy0
But be aware if you intend to host it you will need to protect it from recent AI web scrapers. I use anubis but there are other alternatives.
I wrote a short article about how I configured it there: https://her.esy.fun/posts/0029-ai-assistants-in-doom-emacs-3...
One thing I really appreciate with gptel is that it is very easy to switch from Claude to something else like a local llm (via ollama or gpt4all for example). And the interface will be similar.
Mainly they listen to the interview, and write down answers in an overlay for you to repeat. They ace leet code, etc...
I guess this is already pretty close.
I never used it seriously, but the concepts are easy enough to grasp.
Have a separate dedicated branch that contains all the metadata of your project. Like issues, todo-list, review comments, etc...
Hopefully, something decentralised like this could become more popular maybe.
So this only really mean:
Purely Functional Programming by default.
In most programming languages you can write
"hello " + readLine()
And this would intermix pure function (string concatenation) and impure effect (asking the user to write some text). And this would work perfectly.
By doing so, the order of evaluation becomes essential.
With a pure functional programming (by default).
you must explicitely separate the part of your program doing I/O and the part of your program doing only pure computation. And this is enforced using a type system focusing on I/O. Thus the difference between Haskell default `IO` and OCamL that does not need it for example.
in Haskell you are forced by the type system to write something like:
do
name <- getLine
let s = "Hello " <> name <> "!"
putStrLn s
you cannot mix the `getLine` directly in the middle of the concatenation operation.But while this is a very different style of programming, I/O are just more explicit, and they "cost" more, because writing code with I/O is not as elegant, and easy to manipulate than pure code. Thus it naturally induce a way of coding that try to really makes you conscious about the part of your program that need IO and the part that you could do with only pure function.
In practice, ... yep, you endup working in a "Specific to your application domain" Monad that looks a lot like the IO Monad, but will most often contains IO.
Another option is to use a free monad for your entire program that makes you able to write in your own domain language and control its evaluation (either using IO or another system that simulates IO but is not really IO, typically for testing purpose).
This is probably not the easiest "framework" (not sure this is a good name for it) but it was very fun. I think, if I had to progress from just a toy to a really strong, user facing UI, I think it would still be a pretty good choice. If some feature is missing, or something doesn't work as I would have liked, I know it will not be difficult to correct it myself.
I know that this could feel overwhelming, but this is freedom in a world where you expect there exists a single "best practice". As long as the tool is powerful enough it will be fine. On my end, I appreciate the fact there is not a single "web framework" in Clojure. Instead you have tons of libs you can use that work well together because they are all tied with a few common concepts (like ring for example). If you don't like to choose the libs. There are a few people that provide a starter pack with somewhat nice bundle of libs in a single system like pedestal or luminus for only citing two of them.
My recommendation is to not lose too much time looking for the best choice. Most of them will be good.
Still a smart enough system might be able to discover a valid email from my other id info, like my name. But this start to be a lot of work, while just `s/+[^@]*@//` is easy enough to do.
The code is structured in such a way that you only start the sub services you need. We have node that launch almost all services, some only a few.
If we need to scale just a particular part of the system we can easily just scale the same node but configuring it just for the sub services we need.
But I still loved, it. And it changed every year, and I was even part of the proponent of the changes.
But after a while, you realise that your old project stop working. That if you want to use a new library, you also need to update many dependencies. But each one has breaking changes, so you start updating your code.
Mainly, if you wrote some code, and forget about it, it will no longer work or will be very hard to use with newer libraries. After a while this became very tedious.
In Clojure, the code I wrote 10 years ago is still working perfectly today. The application still launches.
If a bug is discovered and I need to fix it, for example, by upgrading or adding a new lib, I am not afraid to loose hours finding an fixing my existing code that suddenly become deprecated.
So yes, stability is VERY important for me now.
And last but not least, Rich Hickey talked about it in this talk and make a lot of very great points:
I feel that due to its functional nature or perhaps this is just the community bias, Clojurists tend to prefer mixing lower level libraries to build their web application instead of relying on a specific big web framework like RoR for example. Luminus would be one RoR-like system.
But today, I think people would probably choose reitit for the writing the API and use a clojurescript framework for the frontend or perhaps still use reitit to generate HTML pages using hiccup.
I saw some people asking for a good RSS reader. Personally I will use elfeed, and I also use elfeed-org so I could import the OPML file and export it into my existing RSS feeds.
I blog about functional programming (haskell, clojure), but also emacs org-mode, thing like these. I sometimes tell myself I should invest more time to write down more about my thoughts there.
I am happy to be part of the 512kb club.
Here are a few posts that were somehow popular:
- https://her.esy.fun/Scratch/en/blog/Learn-Vim-Progressively/
- https://her.esy.fun/Scratch/en/blog/Haskell-the-Hard-Way/ (updated by https://her.esy.fun/posts/0010-Haskell-Now/index.html )
- https://her.esy.fun/Scratch/en/blog/Yesod-tutorial-for-newbi...
1 + x * 2 - 3 % x
is longer to decipher than (% (- (+ (* x 2) 1) 3) x)
which is itself harder than (-> x (* 2) (+ 1) (- 3) (% x))
But it takes a while to be used to it.
And yes, it really helps writing macros, but I wouldn't say this as always be a good thing. Macros are far from being the alpha and omega of programming, as they add an implicit layer of transformation to your code making it easier to write but very often harder to read and reason about.The positive side effect is that I am reading scientific articles more often since I'm doing this.
I blogged about it here https://her.esy.fun/posts/0021-my-personal-environment-sync/...
https://her.esy.fun/posts/0018-makefile-as-static-site-build...
I use org-mode instead of markdown. But this system is agnostic of your source. Low maintenance, and will probably still work in a long time in the future. The most fragile part of it is pandoc, which I think will be retro compatible for a long time.
- my websites with nginx
- IRC (ngircd)
- ZNC
- espial for bookmarks and notes
- node-red to automate RSS -> twitter and espial -> pinboard
- transmission
- some reddit bots manager I’ve written in Haskell+Purescript.
- some private file upload system mostly to share images in IRC in our team
- goaccess to self host privacy respecting analytics
At home, Plex.
https://her.esy.fun/slides/git-project-manager.html
Mostly, project-management features.
Advanced: log structured objects (keys and string values) to Riemann. Write smart rules in Riemann then send those to ES and explore structured object in Kibana.