What I Learned Today!

A page to record everyday learnings by Arun

A tree is considered dead if it does not grow, it is true for a human as well. The day we don’t learn, we don’t grow. When we don’t grow, we will cease to exist

– Some Wise Human
I am going to use this page to record my learnings on a regular basis. It may be of use to others for whatever it's worth. For me it will stay as a log.

Even if it is 1 inch a day, at the end of 100 days, one would have moved 100 inches which is “much much much” better than ZERO inches.

– A TEACHER

The information on this page is in reverse chronological order


2022

Week 21, 2022 (23-May-2022 to 29-May-2022)

Tech: Full Stack vs Full Spec

The buzzword in today’s world is full stack. There are many so called full stack developers and claim to have expertise in both the frontend and backend. While it is great to have an engineer with experience and expertise in both frontend and backend, they are like the phoenix or nightingale. Of course one could maintain both the frontend and  backend or could develop a full stack application that suits a small business however when we get to enterprise grade applications, having the ability to go from the frontend to the depths of the backend is not practical. It is a different ball game altogether.

On the other hand, the concept of full spec developer is very practical. In terms of a full spec engineer it is not about knowing the depth, but about the breath of software development from good development practices to the production release and everything in-between. It is a much better approach in my opinion for an engineer to professionalize in. Of course, one could not be the master of all of it, however, with consultancy from experts, one could effectively manage all of it very well.

Tech: PlusCal / TLA+ 

PlusCal is a formal specification language created by Leslie Lamport, which transpiles to TLA⁺. In contrast to TLA⁺’s action-oriented focus on distributed systems, PlusCal most resembles an imperative programming language and is better-suited when specifying sequential algorithms.

TLA+ is a language for writing precise high-level models of what code does and how it does it. The more complex a system is, the more important it is to make it as simple as possible.  In complex systems, simplicity isn’t achieved by coding tricks.  It’s achieved by rigorous thinking above the code level.

https://lamport.azurewebsites.net/tla/high-level-view.html

Week 20, 2022 (16-May-2022 to 22-May-2022)

Tech: Page Rank

Page Rank is one of the key factors Search Engines use to gauge the quality of a website to determine its rank on the page (The order in which the page appears for a search). The base work was done by Robin Li called RankDex and is used in Baidu. Larry Page and Sergey Brin developed PageRank at Stanford University in 1996 as part of a research project about a new kind of search engine under the paper titled, “The PageRank Citation Ranking: Bringing Order to the Web” on January 29, 1998.

According to Google,

PageRank works by counting the number and quality of links to a page to determine a rough estimate of how important the website is. The underlying assumption is that more important websites are likely to receive more links from other websites.

The algorithm is still sound and is the basis of most search engines. More learning about it here. 

Week 19, 2022 (09-May-2022 to 15-May-2022)

People: Leslie Lamport

It is sad that I came across a great computer Scientist Leslie Lamport – the winner of the 2013 Turing Award (the noble price for computer science) only this week. He is one of those scientists whose seminal work in the field of distributed systems – the logical clock or Lamport timestamp, is one of the key inventions enabling the modern cloud eco-system. One of the other notable works in the field of distributed systems is The Byzantine Generals’ Problem.

He is also the inventor of the consensus algorithm Paxos. The bakery algorithm for mutual exclusion and the Chandy-Lamport algorithm for the determination of consistent global states.

Was surprising to know that he is also the inventor of LaTeX. A game-changer Document Preparation System. 

Another learning about reading him was about formal specification languages and his invention of temporal logic of actions (TLA). Among his more recent contributions is TLA+, a language for specifying and reasoning about concurrent and reactive systems.

Tech: /proc (slash proc)

Called slash proc, the virtual file system can be considered the control and information center for the kernel. It provides information about each active process. The name of each directory in the /proc is a decimal whole number corresponding to the process ID (PID). It is an interesting read to all the information that is held in the PID directory, how read and write is optimized so as to not disturb the system, especially if you’re interested in the wonders of the *nix world.

Ref:

IBM AIX Proc

PROC in Linux Filesystem Hierarchy

Week 18, 2022 (02-May-2022 to 08-May-2022)

Math: Primality Test 

Primality test is something that is simple in terms of understanding and is often a test for programmers during interview. However, as with all things life, the scale is directly proportional to complexity. As the size of the number increases the problem becomes largely complex that it has taken decades to come up with solution and still researchers are working on finding optimal solutions.

The area and the different approaches are interesting and is always a challenging programmatic question to solve as well, especially for very large numbers. Worth a read about general methods in the Wikipedia post.

Life: You could be nothing. It’s all about where you choose to be that could make you everything!!! 

Zero (0) ideally has no value, when it is alone. However based on where it is placed, the value increases exponentially. However, even when on the high value side, an inhibitor (dot) can void its value. This applies to life too.

Week 17, 2022 (25-Apr-2022 to 1-May-2022)

Life: Procrastination is a sin

Many times in life when someone asks for something or for that matter asks anything, a prompt (well thought about for sure) “no” is better than a delayed “yes”. Procrastination in any sense forces things to decay, then stink and in the end, when you go back to it, it would be untouchable.

This is something that I keep telling myself and practising on a daily basis, a habit hard to master. Will master for sure. In the process, a learning was about prompt replies, even when it is a “no”, than allowing things to decay.

Procrastination is a sin, when commited, even you cannot forgive yourself.
Tech: Building a Slack bot using Slack Bolt Python SDK

It was a use case in the office to have a slack bot that will help cross-functional teams find the on-call engineer for supporting investigations. The idea was to have a simple slack bot that will look into the on-call rota and provide the handles of the engineers’ on-call. I started off with this as the object and ended up learning to build a slack bot using the Slack Python Bolt SDK using Web Sockets for communication. It was a nice experience and learning.

Ref: https://slack.dev/bolt-python/tutorial/getting-started

A screenshot of the bot in action