Random Tech Excursions

  • How to Add a New Module Dependency in VSCode TLA?

    TLA+ has community modules that user modules can extend from. The Github repository tlaplus/CommunityModules houses these community modules. The community modules are packaged as a jar file. If you are using TLA Toolbox, then you can add the jar file in the classpath and use the community module in your TLA modules. The README files includes a link to a video that shows how you can include the module in your code.

    Read more…
  • Where is the Specification File in TLA+ VSCode Plugin?

    I am using the excellent Visual Studio code plugin, TLA+, for writing TLA+ code, and running the code. The plugin makes it easy to write PlusCal code by providing syntax-highlighting, and syntax checking. The plugin can run the specification through the tlc checker, and report errors or success. The plugin makes it easy for people familiar with VS Code to write the specification and run them in an authoring mode that is familiar to them.

    Read more…
  • Design Round - Synechdoche, Long Running Project

    In the movie, Synechdoche, New York, a theatre director, embarks on a mission to create a magnum opus which mimics reality. In his pursuit, he creates a miniature version of every aspect of his life - from physical space to his relationships. As the production progresses, the warehouse resembles life outside, right to the lowest level of detail. Not unlike the mission, in a technical design round, you’re expected to design a smaller scale version of the project.

    Read more…
  • Multiprocessor Programming - Back to the Future

    Why Go Back to the Drawing Board Writing correct programs is hard; writing correct concurrent programs is harder. Multi-threading throws beginning Java Programmer off, and I’d argue some seasoned programmers as well. Many senior Java programmers do not understand the concept well. This is because the concepts are not applied in a day job. Suppose you’re not working in a Java shop like Investment banks that use multi-threading concepts. In that case, you’re not likely to come across the concepts in a regular run-of-the-mill Spring CRUD web application.

    Read more…
  • Preparing for Technical Interviews: A retrospective

    I dread Programming Interviews. I have been programming for a while now (over a decade), but attending a programming interview is still a humbling experience for me. You get rusty, and the inertia to start the preparation all over is too daunting. Treating the preparation as an opportunity for self-development regardless of outcome is something that gets me started. If you are embarking on your preparation for interviews, then I hope you find these pointers helpful.

    Read more…
  • upper_bound and lower_bound in Java Standard Library

    Sometimes, there are simple things that fly under your radar. C++ has upper_bound and lower_bound that return the elements that are bounds for a given element in a sorted array or collection. Python has a similar bisect module that has functions bisect_left and bisect_right. I did not find similar functions in Java Standard Library. I would resort to following the binary search again over the collection or array to find the bounds.

    Read more…
  • Save Disk Space when Installing Jetbrains Products

    I am a fan of Intellij Products. I use them for coding in my personal and professional projects. I have bought a subscription for the entire suite of Intellij Products. Those who bought the suite will know that the suite comes with a “Toolbox” app. The “Toolbox” app keeps the line of products installed on the computer up-to-date. Off late, I saw that disk space used by Intellij Suite grew exponentially.

    Read more…
  • Writing Pipe-able Python Scripts

    I have written many Python scripts over the course of many years. I wrote the scripts for tasks like data cleanup, data extraction, integration scripts and what not. In retrospect, the majority of the scripts I wrote were standalone, or custom unix bash scripts glued them together. Recently, I had an opportunity to write a Python script which was a part of a larger pipleine of scripts for data transformation. I wanted the script to be used in the pipeline without any custom glue code.

    Read more…
  • Umberto Eco's Index Cards in Notion

    Imagine what it was like doing any kind of research before the internet. What would have been the older tab-switching-browsing-bookmarking equivalent? How would someone who was doing research, selected, copied, and pasted text from the reading material? I imagine they would have copied the text by hand and annotated the source material in their notebook. Doing research was an arduous task in the early days without the internet. The thought of researching in pre-internet days is what makes reading Umberto Eco’s “How to Write a Thesis” much more enjoyable.

    Read more…
  • From Tasks to New Checklists

    In a post from before, I wrote about a new workflow that I had been following lately. I took inspiration from the PARA workflow, mental models, and checklists to create a personal workflow. The post was brief, and I feel that the Checklists' generation part needs a bit more elaboration. In this post, I wanted to expand upon one of the workflows. How can you create a new checklist or improve an existing list by reflecting upon what you did in your last project?

    Read more…