HACKER Q&A
📣 joaogui1

Hello, World


People always talk about coding "Hello, World!" as a rite of initiation in a new programming language, but some folks have more elaborate programs/algorithms that they implement when learning a new language as a benchmark for their language learning (https://www.xavierllora.net/2014/03/22/yet-another-cga-implementation-now-in-haskell./) What is the program you always code in a new language to test how much you've learned?


  👤 ColinWright Accepted Answer ✓
The program "Hello World" isn't anything to do with learning the language, it's about:

* How do I create a program?

* How do I store a program?

* How do I run a program?

* How do I get the program to output something?

So your first statement seems to miss the mark.

To answer your question, if I'm learning a new language it's usually because I have a specific problem to solve, so I write "Hello World", and then start to grow the program into what I need. I don't have a toy problem to implement as a test.

Probably not the answer you wanted.


👤 karmakaze
It's usually either: arbitrary like Advent of Code or Project Euler to see what it's like using the new language for sorts of things I know how I'd do in ones I normally use; or start/port my latest project idea. Most often the back-end to some web app that does something specific or perhaps a library to see how far a bad type system can go (e.g. typesafe SQL queries in Java vs Kotlin or F#).