this post was submitted on 25 Feb 2024
101 points (100.0% liked)
Programming
17668 readers
225 users here now
Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!
Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.
Hope you enjoy the instance!
Rules
Rules
- Follow the programming.dev instance rules
- Keep content related to programming in some way
- If you're posting long videos try to add in some form of tldr for those who don't want to watch videos
Wormhole
Follow the wormhole through a path of communities !webdev@programming.dev
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
What's DSA ?
It's a term that generally refers to the more 'mathematical' side of programming, as opposed to the more 'practical' side of things. I believe it means 'Data Structures and Algorithm' so its a generalization of 'meaty' programming. Think, someone who writes shell scripts does not need 'DSA' to oil his grind, but someone needing to write a compiler does.
Now we live at an age where you can generate a shell script with a simple prompt, and hell, you could piece-meal a compiler, but it's not as straightforward. If one wishes to make moola in the post-LLM world, one needs to have strong theoretical and constitutional foundation.
At this point, any employer who hires more than 1 person for the 'simple tasks' is doing charity. And charity ain't what employers known for!
That is not to say, don't use AI in your work. I believe AI is the BEST way to learn DSA. In fact I straightened a lot of my misconceptions using ChatGPT. Like, I have written 2 compilers and abandoned them because I never meant to finish them, it was an excuse to prompt ChatGPT with more complex requests and do some reckon on my knowledge. I managed to do 'basic' SSA with ChatGPT, and anyone who has read a compiler book or taken a class knows SSA is not easy. I generated the SSA, and confirmed with the SSA book that I had. IT was very decent. But ther SSA book was very 'crude' and ChatGPT's example was really, well, 'uncrude'? So it was a GIANT help in me understanding SSA.
So if you need to learn DSA, I can recommend these three steps:
1- Learn a functional language or LISP-like language, Scheme, Racket, OCaml, SML, Haskell, etc. These langauges are extremely fluid and scientific.
2- Read books. Just go on Libgen or Zlibrary and read books. I recommended SIpser's above (or was it in another post?) but there's dozens. I remember a book called "Grokking Algorithms" which was really good. I read this book when I was sick with Covid, Steven Skiena's "The Algoritmh Design Manual" and it seems like everyone just LOVES this book. I mean it, try it, it's the best. If you can, buy it, because it's very precious. Also, keep a copy of CSLR/CLSR or whatever as a reference on your desk, PC everywhere.
3- Piece-meal ChatGPT into designing you a complex application. It really helps if you got an aim. One thing I recommend is Genealogy software. Make a Genealogy DSL perhaps. Or a simple compiler.
My advice may not be sound, but some aspects of these were helpful for me.
Thanks for the advice. I was already pretty sure that learning DSA would take my programing to the next level, my previous algorithms have been thoughtful but could definitely be improved.
I've done some haskell for school, I must say the quick sort was quite impressive and the language itself was interesting. Lisp on the other hand seems really crazy ; I've done some for my emacs config but the things I'm reading from the sources are from another world, I'll read the elisp introduction some day and maybe I'll become one of those magicians lol
I don't really use AI but I could ask for some advice on my next school project I guess. Do you ask it for straight up code or a more global archetecture ?
I give it half-baked code and ask it to complete it. Like say a few days ago, I wanted to implement NFA and Thompson Consturction. So I wrote this:
This is how you get good results from it. Do half the work.