Blog

I write here. So far I've written around 35-50 articles. At the moment, articles I've published have garnered around ~250,000 views. I sometime repost articles on the DEV community, where I interact with other devs as well.

If you catch an error or problem in one of my articles, feel free to email me: gabriel@gabrielromualdo.com.

Building Software to Fix Thousands of Errors on the NY Times

Last year I was working on a project for a history class and I noticed a recurring, common error in these transcribed articles: there would commonly be an extra space in ...

Random Seed in JavaScript and Node.js

Random Seed in JavaScript and Node.js

  • March 26, 2021

  • 2 min read

Random seed is a method of initializing random number generators using an initial seed value. Random generators with the same seed will output the same pseudo-random resu...

An Algorithm to Swap Two Variables Synchronously, Without Creating a Temporary Variable

Let's say you want to swap the values of two integer variables, a, and b. Simply setting a equal to b and then b equal to a does not work, since a and b would just end up...

How to Set Up Rate Limiting and Rate Slowing Down in Express.js

Rate limiting is the process of preventing repeated requests to a server in effort to remove spam requests. Typically, a limit is set, such as 200 requests to the server ...

Programs to Compute Trig Functions in Python, JavaScript, & Perl (with Maclaurin Series)

Have you ever wondered how your computer calculates certain mathematical functions, like division, or trigonometric functions like sine or cosine? Well, for some of these...

How to Use the HTML5 Gamepad API (with complete examples)

The HTML5 Gamepad API is one of the more exciting HTML5 APIs in my opinion. The API allows browser games and sites to take input from real game controllers connected to t...

How to Schedule Cronjobs in Python

How to Schedule Cronjobs in Python

  • December 12, 2020

  • 2 min read

Cronjobs are tasks that can be run periodically, such as every five minutes, or every day at midnight, or even every Friday at noon. Cronjobs have a number of different u...

How to Generate the Sierpinski Triangle in Vanilla JavaScript with HTML5 Canvas

The Sierpinski triangle is a famous mathematical figure which presents an interesting computer science problem: how to go about generating it. In this article I'll explai...

Performance of AI Algorithms in Playing Games — Empirical Evidence From Jupiter, My 2048 AI

I recently worked on an open source project called Jupiter, an online AI written in JavaScript to beat the popular online game 2048. In this article, I'll be analyzing th...

Using the Monte Carlo Tree Search Algorithm in an AI to Beat 2048 (and other games)

I recently worked on an open source project called Jupiter, an online AI to beat the popular online game 2048. In writing this AI, I decided to use a machine learning met...

I Built Jupiter – A Machine Learning Based 2048 AI that Runs on the Web

Today I'm proud to release my online 2048 AI, Jupiter. Jupiter uses a machine learning method called the Monte Carlo Tree Search (MCTS) algorithm. I've released an articl...

How to Parse XML in Python

How to Parse XML in Python

  • August 8, 2020

  • 3 min read

I recently spent a few hours refactoring some of the backend code on this site at xtrp.io. In changing the backend, I wanted to make sure the refactored code worked the s...

Build and Deploy a Discord Bot with Node and Discord.js in 5 minutes

Discord bots can be useful in doing a variety of things like playing music in a voice chat, or sending automated announcements when a Youtuber releases a new video. I'm a...

How to Create a Beautiful Custom Scrollbar for Your Site in Plain CSS

Custom scrollbars on the web can make a site or design stand out. They can help in portraying key design aspects of a site, whether that be a specific color or a particul...

AP Test Submission Problems Show Lack of Developer Adoption of .HEIC File Type

Due to lockdown and quarantine in numerous countries, this year's AP tests were moved to an online platform created by College Board, the creator of the AP program and ot...