• 0 Posts
  • 19 Comments
Joined 1Y ago
cake
Cake day: Jul 10, 2023

help-circle
rss

I save “template” SQL queries in a special directory so that I don’t have to google how to do specific things. It’s basically my own personal “examples” folder.



The bit of Clean Code that I read was unimpressive, but Clean Architecture was amazing. I view that book as required reading for anyone who wants to write code professionally. If Uncle Bob hasn’t realized that his coding style is worse than alternatives, I do not see how a second version of the same bad ideas is going to do well.


What if instead we utilized an algorithm, some code, that would ultimately generate the file? I could imagine a program that generates a number which ultimately is more dense than the program. For example, if we just-so-happened to need a million digits of Pi the program would be shorter than the number. Is there a way to tailor an algorithm to collapse down to any number? As an example, what if we needed a million digits of Pi but the last 10 digits need to be all 9s?


Do you happen to know of any good algorithms or numbers? Pi gets harder to calculate with each digit, so it’s not a great candidate.



Is there an algorithm or number such that we could basically pirate data from it by saying “start digit 9,031,643,679 with length 5,345,109 is an MP4 of Shrek”? Something that we could calculate in a day or less?


It’s still useful when it’s wrong because it can give you the jist of what should be done. If it uses a library or function that doesn’t exist, you’ll still be informed as to what it was intending for the process at that point. I’ve often gone and just replaced the made-up code with custom code that does the same thing.



It’s surprising how useful ChatGpt is in these situations. Honestly, it’s a great general purpose search engine.



Cursorless. It’s a spoken-language programming interface that allows the programmer (of basically any language) to use specific words to target existing text, move the underlying cursor/selection relative to that target, and then run a specific modification. Think of VIM but for voice. It runs in VSCode atm as a couple extensions along with an install of the audio tool Talon. https://www.cursorless.org/


My current favorite is mostly Rust-based with the tide crate, tide-jsx crate, vanilla JS, postgres crate, and Postgres in Docker. Super easy, super fast (to develop and run), but I haven’t made any large web projects with this stack yet, just small stuff.


As someone who learned a lot from C++ and that now loves Rust, this annoys me.


That would be cool, seeing RGB GOL cells moving outward. Maybe instead of 0 or 1 brightness you could just round it for the cell’s purposes, maybe having a const float for flexibility: if it’s greater than threshold then it’s “on”.


That’s awesome! What are your thoughts on keeping the colors of your face as they naturally are and as the GoL algorithm acts on the pixels, you blend the colors together?


Can you please elaborate on how, when using Rust, we can avoid needing to debug our JS code? I am very interested and hope that I didn’t misunderstand you.


From my experience JS is primarily used to manipulate the DOM. I haven’t looked into it, but if you’re correct that WASM cannot manipulate the DOM then your question, to me, is tantamount to “Why aren’t people using forks to eat soup?”.

I would love a staticly-typed, compiled language to come along and replace JS. If anyone is aware of how I can write Rust in place of JS, please let me know. For now, I suffer/enjoy JS.


When I see a RIGHT JOIN I just shake my head and wonder “Why?”. That said, I can’t remember the last time I saw one.