-
Universal types, and your type checker doesn't suck as much as you think
Universal types are very useful for performing generic programming, which allows you to use the same code over different types. For instance, the C++ STL (Standard Template Library) allows you to work on things like containers over any arbitrary type. You would surely not want to re-implement the logic for every concrete type that you use. Such a feature is known as parametric polymorphism. It is different from the other kind of polymorphism normally found in object-oriented languages that allows for overloading and run-time dispatch, which is known as ad-hoc polymorphism. In this post, we understand the theoretical foundations underpinning universal types, and conclude with the landmark result that typechecking with universal types is undecidable.
-
Against Government Scholarships
Over the past few years, I've received numerous questions about studying abroad and whether it is advisable to take a government scholarship to do so from my juniors. Having witnessed firsthand the early career trajectories of many scholars and non-scholars alike, and having heard their different perspectives, I feel like I have a good understanding of the concerns at hand to answer this question confidently. This post is aimed at Singaporean junior college students debating whether they should take on a scholarship from the government to pursue a fully-paid education abroad. In this post, I will consider both the pros and cons of taking a scholarship. The relevance of some of the points is highly dependent on your current situation, so ultimately take it with a grain of salt and consider your unique circumstances. It is useful to keep in mind that a scholarship is designed to benefit the government's interests, not your own.
-
Why you can't create a value with the Bottom type (and why it's still useful)
If you've used any sort of object-oriented language, you may be familiar with the notion but not the name of the top-level type \(\top\). For instance, in Java, the `Object` class forms the root of the class hierarchy, and similarly, in Python, all objects inherit from `object`. Analogously, there is also a bottom-level type \(\bot\), but it cannot be instantiated by any value in any language. This post will explain why.
-
Quantum physics inaccuracies in Seishun Buta Yaro (Rascal Does Not Dream of Bunny Girl Senpai)
I finished watching Seishun Buta Yaro (Rascal Does Not Dream of Bunny Girl Senpai) recently, and really enjoyed the anime. It explored themes of finding one's identity, and dealing with social anxiety during adolescent years. In the show, students are inflicted by a fictional disease called Adolescence Syndrome when they are severely affected by the things happening around them, whose symptoms depends on the specific reason why a person is mentally distraught. Rio Futaba, the president of the science club in the school, tries to explain the reasons for Adolescence Syndrome using quantum mechanics principles throughout the show. Unfortunately, most of it was poorly applied, and could be harmful in reinforcing misconceptions of quantum mehanics. In this post, I examine each of her claims and describe why they don't really make sense. This post is aimed at a general audience and requires no knowledge of quantum mechanics.
-
Writing a DPLL SAT Solver
Boolean satisfiability (SAT) solvers have played an important role in software and hardware verification, automatic test pattern generation, planning, scheduling, and solving challenging problems in algebra. In this post, I talk about my experience writing my own SAT solver, its implementation details, designs and algorithms used, some comparisons between using different heuristics for splitting and choosing of variable assignments in the unforced case, challenges faced, and possible future directions.
-
Playing Atari using Deep Reinforcement Learning
In this post, we study the first deep reinforcement learning model that was successfully able to learn control policies directly from high dimensional sensory inputs, as applied to games on the Atari platform. This is achieved by Deep Q Networks (DQN).
-
HopSkipJumpAttack: An Efficient Adversarial Attack against Machine Learning Algorithms
Many machine learning algorithms have been shown to be susceptible to adversarial examples. For example, image classification neural networks can wrongly classify an image when a small perturbation, unnoticeable to the human eye, is added to the original image which it has previously correctly classified. The goal of an adversarial attack can thus be rephrased as an optimization problem to compute the "smallest" perturbation needed, such that the perturbed example will be misclassified.
-
Breaking CMU's Bomblab with Angr for Fun and Profit - Part 7
The final part of cracking CMU's Bomblab with Angr, where we crack the secret phase together!
-
Breaking CMU's Bomblab with Angr for Fun and Profit - Part 6
We tackle Part 6 of this series on cracking CMU's Bomblab with Angr!
-
Breaking CMU's Bomblab with Angr for Fun and Profit - Part 5
Part 5 on cracking CMU's Bomblab with Angr, where we solve Phase 5 together!
-
Breaking CMU's Bomblab with Angr for Fun and Profit - Part 4
Part 4 of cracking CMU's Bomblab using Angr!
-
Breaking CMU's Bomblab with Angr for Fun and Profit - Part 3
We're back now with Part 3 of this series on cracking CMU's Bomblab using Angr!
-
Breaking CMU's Bomblab with Angr for Fun and Profit - Part 2
This is Part 2 of the series on cracking CMU's Bomblab using Angr, where we solve Phase 2 by pushing symbolic values onto the stack to
-
Breaking CMU's Bomblab with Angr for Fun and Profit - Part 1
I have recently been learning about Angr, a binary analysis framework developed by UC Santa Barbara and Arizona State University. It caught my eye because of its versatility and utility in reverse engineering binaries whose disassembly and decompilation are hard to understand manually. Oftentimes, it is simply due to the fact that it was compiled from newer or relatively less popular languages like Rust or Haskell, where the state of currently publicly available decompilers leaves much to be desired. Angr's ability to perform symbolic execution therefore allows us to blackbox certain functionality within the program (or even the entire program) by attempting to find the right input for a desired output.
-
UIUCTF20 Accounting Accidents Pwn Writeup
UIUCTF20 was a really fun Animal Crossing themed CTF that ran from July 17-19 2020. While I have not played the game before, I somewhat knew what it was about from watching Youtubers play it, and also from memes about the turnip stock market. Our team PPP came in third place, which went above my expectations as most people playing were relatively new and I am quite happy with the result. Now, on to the writeup!
-
Pink Floyd and Alienation
In this post, I talk about how themes of alienation pervades the music of the English rock band Pink Floyd. Pink Floyd is one of the greatest bands in popular music history, achieving international commercial success and widespread influence in subsequent musical developments. They formed in London in 1965 to humble beginnings as a student group, and comprises Syd Barrett (guitar and lead vocals), Nick Mason (drums), Roger Waters (bass guitar, vocals), and Richard Wright (keyboard, vocals).
-
Persisting Xserver Multimonitor Setup
I have been using a multiple monitor setup on my Linux system for a long time, and one thing that always annoyed me was that the default monitor arrangement detected by X Server doesn't reflect its physical positioning (why should it?). Due to a combination of laziness and the fact that reordering it with nvidia-settings's X Server Display Configuration takes only a few seconds, I never bothered to find the time to find a proper fix for it. However, the fix is actually incredibly simple.
-
A New Look
My Jekyll blog has been on the default minima theme since its inception. It was functional and served its purpose, but as someone who has extensive web development experience having designed and implemented sophisticated web interfaces back when I was working at Saleswhale, I felt like I could definitely do much better. This post talks about how I re-themed the blog.
-
Dev Cheat Sheets
Today I created a new tab for my blog, 'Dev Cheat Sheets'. This page will contain common commmand line commands that I use often. I have a habit of simply performing a reverse-i-search on my terminal when I need a particular command, and therefore I have never really bothered to firmly commit them to memory or find a proper place to record them. However, this gave me problems when...
-
My Involvement in the Autolab Project
I joined the Autolab team at the close of the semester this year. The Autolab team builds and maintains Autolab, an autograding platform for programming assignments that is currently being used by around 20 universities around the world. It is used very extensively in most computer science courses to grade programming assignments in Carnegie Mellon. In this post, I will share how I came to join Autolab, and the role that I am planning to play in it.