Time formatting in Go
A little cheat sheet to help remember the Go time formatting syntax.
A little cheat sheet to help remember the Go time formatting syntax.
My attempt at FizzBuzz in Nim.
Nim 0.18.0+ ships with the strformat
library that provides the fmt
template which allows one to format strings using format specifiers
like in Python 3’s f-strings.
You write it just like that in the title — “Org” with capital “O”, and then lower-case “mode” separated by a space.
Collection of Nim snippets with brief notes as I try them out from the official Nim tutorial, Nim by Example and many other places. This also includes my own musings and hard-learned lessons.
When writing bash scripts, I often need to know if the script is receiving input from the terminal, or some piped process. I would also need to know if the script is sending output to the terminal, or to another piped process.
As I am learning Nim and trying to write new scripts using that, I need to know how to do the same in Nim.
Spoiled by being able to access in-built docs in Emacs at fingertips,
here’s an attempt to kind-of do that for Nim documentation too,
using devdocs.io
.
Collection of awk
examples.
Follow-up post to my earlier post on octals in Golang – Feedback to reactions that varied from ridicule to helpfulness to empathy.
Someone in the Golang team thought that it would be a good idea to consider all numbers (represented as strings) starting with “0” as Octals.. so “010” is actually 8.. Really?