All the others have great suggestions but I’d just like to add there many open source projects out there and given example code of how something is done and letting him play with it can be tremendously helpful. For example finding some simple 3d programs and lettting him change the source code to do whatever he wants or just giving him a template like https://editor.p5js.org/1alimaze/sketches/IJpxIEME8 which I made when I was first learning and letting him play with the values and add more objects.
Although I do believe Javascript is a mess, I’d have to disagree with that. The problem with Javascript and to an extent all client side code is that people uses as a everything tool not neccesarily the language being at fault. People should start to realize handling logic on the backend is perfectly fine and is often better as you don’t need to send several megabytes just to load a simple web page. If we decided to replace Javascript with Python we just recreate the same problem that plagues the modern web.
Shorter is usually faster so your right on that account but not always. There are few things like optimizing for cache hits that can vastly speed up programs but are hard to do. Most slow programs are due to technical debt, high dependencies usage, mixed with laziness and lack of interest in developers with speeding up their program.
// Some of my rss feeds
Answering my own question here. If you don’t have any interest in how the tools you use work, programming isn’t “for you” (take that with a grain of salt). If you are writing code and have never looked into how compilers/interpreters work or are using a library and haven’t even taken a peak at the library’s source code you should because it will make you a better programmer in the long run. And I’m not saying you can’t get anything done without that curiosity but curiosity is a major part of being a programmer. Also you don’t need to have a deep understanding of the tool just a overview of what it’s doing. Like for a compiler understanding what lexers, parsers, ASTs, code generators are will allow you to write code with that in mind.
Perhaps garbage collection is the wrong term to use as it dosen’t happen at runtime (I wasn’t sure what other term to call what Rust does). But Rust does provide a abstraction over manual manual memory management and if you are experienced with Rust sure you can probably visualize where the compiler would put the malloc and free calls so it is kind of a mix where you do technically have control it is just hidden from you.
Edit: It seems the term is just compile-time garbage collection so maybe you could consider it falling under garbage collection as an umbrella term.
Essentially although there are a few key differences:
If you want to train your neural nets you can maybe check out: https://github.com/rust-ml/linfa https://github.com/param087/swiftML (Rust seems to have more active support in terms of libraries)
If you want to integrate ML into an IOS/MacOs app: https://developer.apple.com/documentation/coreml
For userland apps Swift would be better and for training or just being generally being more useful in the future go for Rust.
At the end of the day just choose the language that is more enjoyable for you.
Other than having first class support on Apple’s hardware Swift dosen’t have much going for it. There is no killer feature in Swift, it dosen’t widespread features and it only has a small niche. If you want to develop for mainly Apple devices I would say go for it as that is the niche it was designed for. Although I see from your post you want to do ML, Python for the high level stuff + C++ for the low level stuff is probably your best pick for that. May I ask what type of ML are you going for? Are you mainly using libraries like Tensorflow, Pytorch etc… or are you into the nitty gritty of building these things yourself and writing the required code for the matrix math and training algorithms.
Rust on the other hand is multiplatform and super low level
Not to nitpick here, (I agree with pretty much everything you said) but I wouldn’t go around calling Rust super low level as it is garbage collected. The borrow checker acts as a abstraction over the actual malloc and free calls that are happening under the hood.
I agree, unless you doing low level stuff where you need absolute control you should use a modern language with proper abstraction just to save time. Most use cases where they use C++ can be replaced with Rust or Go as they aren’t saddled with years tech debt and bloat due to having mantaining backwards compatibility.