Live data from Hacker News

Ask HN: What do you code when learning a new language/framework?

news.ycombinator.com

131–140 of 171 posts

Re: Ask HN: What do you code when learning a new language/framework?

#131
My go-to projects have varied over time:

1. An implementation of Fisher's exact test for 2x2 tables. This adapts the algorithm from R's fisher.test() function, which was implemented with function closures for optimisation, which does not always map well to other languages.

2. A foreign function interface to the Rmath library. I have now done this for Standard ML (MLton, Poly/ML, Moscow ML, MLkit, SML/NJ, SML# and Manticore), OCaml, Ur/Web, Mercury and MonetDB. Code generation sometimes uses cpp, m4 or the language's tree and string facilities.

3. Discrete event simulation using message passing with an application to cost-effectiveness analysis. Someday, I'll get this published.

Re: Ask HN: What do you code when learning a new language/framework?

#133
Usually I find whatever web framework the language supports. This usually tells you a lot about the language, like if it can hide some of the ugly details behind powerful features or if you get to see it all (nothing wrong with the Go approach of 0 magic), basically everyone can open a browser and see immediate feedback. I also like to see how responsive it is and all that.

It also lets you evaluate any database drivers, which are one of the top 10 things I want out of any language I use.

Re: Ask HN: What do you code when learning a new language/framework?

#134
This comment from a few days suggests implementing ed: https://news.ycombinator.com/item?id=32015912

That strikes me as an excellent idea: it’s a pretty small tool, but it is useful and has just enough complexity to test the language and its standard library. Note, however, that I have not done so myself!

Re: Ask HN: What do you code when learning a new language/framework?

#135
I'm a fullstack web developer. I know "some" devOps. I also develop for mobile but mostly via port frameworks like Capacitor.

I usually build something that'll be easy and can be built in a weekend. Like with Phoenix, I'm thinking of building a multiplayer app since that's the best usage for this specific framework.

Re: Ask HN: What do you code when learning a new language/framework?

#136
I usually try Advent of Code (https://adventofcode.com) every year with a new language I'm interested in. So far it's allowed me to get respectable knowledge of: - Go - Rust - Clojure

Hoping to try out Elixir for this year.

I also sometimes build Conways Game of Life in a new language for fun.

Re: Ask HN: What do you code when learning a new language/framework?

#139
Depends on the language. Since this year I am getting up to speed with JavaScript and TypeScript, and there are a lot of different notions around to learn. It really clicked for me just recently when I implemented my own little unit testing tool (https://www.npmjs.com/package/instatest). This touched many aspects of the ecosystem I needed to know about, and was yet pretty simple to do.

Re: Ask HN: What do you code when learning a new language/framework?

#140
Fastest way I learned was to rewrite an app I was intimately familiar with in the new tech.

e.g. I wanted to move from Flutter and Firebase to Fullstack JS. So I rewrote a 20k lines app in NextJS ( typescript and everything I wanted to try out ).

Not the best way to go if all you want to learn is 1 piece of technology though.

Post reply on HN