New
The latest blog posts to take off on Hacker News. 14,543 posts.
Why I think Haskell is the best general purpose language as of June 22 2019
Me and my close friends have been interested in starting a project together and I suggested we use Haskell. I do not think the suggestion was received well or perhaps in seriousness. I have a tendency to joke about almost everything and have put forward that we use many interesting but not practical languages in the…
Compiler basics (5): LLVM system calls
Writing a lisp compiler from scratch in JavaScript: 6. LLVM system calls
Arima Model – Guide to Time Series Forecasting in Python
Using ARIMA model, you can forecast a time series using the series past values. In this post, we build an optimal ARIMA model from scratch and extend it to Seasonal ARIMA (SARIMA) and SARIMAX models. You will also see how to build autoarima models in python
Avoiding Instruction Cache Misses
Excessive instruction cache misses are the kind of a performance problem that's going to appear only in larger codebases. In this article, I'm describing some ideas on how to deal with this issue.
Writing HTML in HTML
I've just finished the final rewrite of my website. I'm not lying: this is the last time I'm ever going to do it. This website has gone through countless rewrites – from WordPress to Jekyll to multiple static site generators of my own – but this is the final one. I know so, because I've found the ultimate method for…
Why I don't use web components
For my first post on dev.to I thought I'd write about a nice, safe topic that's free of controversy:...
NPM & left-pad: Have We Forgotten How To Program?
Intro Okay developers, time to have a serious talk. As you are probably already aware, this week React, Babel, and a bunch of other high-profile packages on NPM broke. The reason they broke is rather astounding: A simple NPM package called left-pad that was a dependency of their code. left-pad, at the time of writing…
Elegant Error Handling with the JavaScript “Either” Monad
JavaScript gives us a built-in language feature for handling exceptions: try…catch statements. And they’re better than littering our code with if-statements. But they can be problematic. And they are not the only way to handle errors. In this article, we’ll take a look at using the ‘Either monad’ as an alternative to…
Google to Reimplement Curl in Libcrurl
Not the entire thing, just "a subset". It's not stated very clearly exactly what that subset is but the easy interface is mentioned in the Chrome bug about this project. What? The Chromium bug states that they will create a library of their own (named libcrurl) that will offer (parts of) the libcurl API and … Continue…
Fixing a Small Calc.exe Bug
tldr; saw a Windows Calculator bug on reddit . Since calc.exe was open-sourced I thought I’d try to find the bug and fix it. Cloned the code, recreated the bug, and found a minimal fix .
Go Creeping In
I’ve seen the inside of the Google and Amazon tech stacks. There are common threads that run through them and also, I bet, through most BigTechCos. Here and there down the stack is a lot of C++ and vestigial remnants from earlier days, Perl or PHP or whatever. Out in front of humans, of course, JS. But in between…
Classes vs. Data Structures
Or rather, an object is a set of functions that operate on implied data elements.
In Defence of the Technical Interview
Coding puzzles and their prevalence
Comparing the Same Project in Rust, Haskell, C++, Python, Scala and OCaml
During my final term at UWaterloo I took the CS444 compilers class with a project to write a compiler from a substantial subset of Java to x86, in teams of up to three people with a language of the group’s choice. This was a rare opportunity to compare implementations of large programs that all did the same thing…
Uniform Structured Syntax, Metaprogramming and Run-Time Compilation
Real world example where uniform syntax enables unthinkable solution
Introducing a new HTML element – welcome <clippy>
Hello! It looks like you're writing a blog post - would you like help with that? chuckles Me and my colleagues at Microsoft have decided that the world needs more Clippy - the adorable animated paperclip. To help with that, we're bringing a new feature to Edge 6.0. Web Developers can now use <clippy> to call up an…
C++ Patterns: The Badge
This post describes the C++ Badge template used to enhance member function access control in Serenity Operating System.
A Failed Experiment with Python Type Annotations
I like Python, but wish it had static typing. The added safety would go a long way to improving quality and reducing development time. So today I tried to make use of type annotations and a static type-checker called mypy. After a few basic tests, I was excited. But my glee turned to disappointment rather […]
From Design Patterns to Category Theory (2017)
How do you design good abstractions? By using abstractions that already exist.
Micro Frontends
How to split up your large, complex, frontend codebases into simple, composable, independently deliverable apps.