The Magical Coding Interview: A Tale of Prolog, Lisp, and µKanren

2025-01-02

Seasoned programmer Vidrun faces an unconventional interview. Aisha, a three-year veteran engineer, eschews typical questions, instead engaging Vidrun in a coding duel using Prolog and the lambda calculus. Aisha guides Vidrun in building a Lisp interpreter, culminating in Vidrun's clever use of µKanren and custom macros to solve the problem, forging a connection with Aisha through the shared art of coding. This story blends technical prowess with magical realism and interpersonal dynamics, showcasing the ingenuity and artistry of programming.

Read more

POSIX Time: Not What You Think

2024-12-26

This article debunks a common misconception about POSIX time (Unix time): it's not simply the number of seconds since January 1, 1970, 00:00:00. Due to leap seconds, the number of seconds in a UTC day isn't a constant 86,400, leading to discrepancies between POSIX time and the actual number of seconds. The article delves into the impact of leap seconds on time calculations and recommends alternatives like CLOCK_MONOTONIC or TAI for precise timekeeping, avoiding errors caused by leap seconds.

Read more
Development POSIX time leap seconds