[flagged]
Ask HN: What do you code when learning a new language/framework?
91–100 of 171 posts
Re: Ask HN: What do you code when learning a new language/framework?
#92I'm an embedded/real-time/systems software developer. The realms I work in tend to be either the very small or the very large. When I wanted to learn Rust and Go, I coded the same application in both of them, one that I had previously coded in Java, C++, and C: I implemented the Generic Cell Rate Algorithm using a virtual scheduler. The GCRA is a traffic shaping algorithm that takes as parameters a desired peak rate,…
same embedded developer here, my problem is that daily job only needs c/c++ so my skill about python or js or golang is always weak -- after a while I forgot many of their details due to lack of serious need... my problem is: how to keep 3~4 language 'warm' at all times? write some code daily on each?
Then you can swap out all the python/njs/js frameworks to your heart's content.
Re: Ask HN: What do you code when learning a new language/framework?
#93Both stacks are totally great and enjoyable btw, would recommend.
When I first meet a language I usually crack open the docs and then write a single micro project, like a BFS maze solver or a knapsack problem solver or something Advent of Code-esque, just to get to know all the primitives quickly -- different kinds of variables, arrays, dicts, control flow, closures, error handling.
Re: Ask HN: What do you code when learning a new language/framework?
#94Until I do that, and I mean truly do that, I am prone to all sorts of surprises when running my code and have little confidence.
Most recently I’ve done this with fp-ts (a functional programming library for typescript) and a wrapper around hledger (a plain text accounting app). Because the later is Haskell, I figured I might open myself up to a rewrite at some point in the future.
Re: Ask HN: What do you code when learning a new language/framework?
#95What I try is to solve a small piece of the problem I am trying to solve to get more familiar with it before committing.
Re: Ask HN: What do you code when learning a new language/framework?
#96Re: Ask HN: What do you code when learning a new language/framework?
#97Re: Ask HN: What do you code when learning a new language/framework?
#98Re: Ask HN: What do you code when learning a new language/framework?
#99It also helps to practice breaking a problem into steps as an AST is structured in such a way as to encapsulate distinct behavior within a node. Often this will result in using something akin to the Visitor pattern and this helps you further separate behavior from form.
I am a full stack senior dev, work often in Go or Node/JS when building services and React/JS when building front ends.
Re: Ask HN: What do you code when learning a new language/framework?
#100I build an Abstract Syntax Tree (AST) and usually something with a fluent interface that builds a query. I find this helps me understand the nuances of interfaces and inheritance in a given language and I’m generally interested in the problem so I tend to get far enough to really learn something. It also helps to practice breaking a problem into steps as an AST is structured in such a way as to encapsulate distinct b…