Category: Technology

My Controversial Interview Tactic

I am often faced with the question of what makes a good technical candidate. Many companies require an engineering degree in their job descriptions. Many high-functioning delivery teams consist of qualified engineers working on real-world problems, and I have learned a great deal from such engineers, who were at the peak of their powers.

However, I have survived for twenty years in the treacherous, competitive, and sometimes maddening software industry in India with just a B.Com degree. Stubbornly, I did not pursue a formal degree in computer science, instead learning everything from the ground up. My journey has taken me through some of the best companies in the world. Despite this, getting a job has been significantly harder for me than for a candidate with an engineering degree. Search engines and criteria rarely surface resumes of non-engineers, and recruiters, in their naivety, often overlook potentially valuable resumes. Does this make me a good technical candidate?

Throughout my many interviews over the years, I have sought candidates like myself – non-engineering graduates. I have, however, recruited only one such individual. A non-engineering graduate with technical proficiency is a rarity, mostly because few understand the history of computer science and how everything works at its most fundamental level.

This holds true even for engineering graduates. Many come from non-computer science backgrounds and pursue computer science simply because it pays more. In my campus recruiting efforts, I found that even many computer science graduates from second-tier colleges had questionable practical knowledge of how things worked. The IITs and RECs tended to produce the best engineers, and we saw better recruitment averages from these institutions.

My Effective Strategy for Technical Interviews

The most effective strategy I’ve found is to focus on the absolute basics. If I am recruiting for a UI role, here’s what I typically do:

  1. Start by thoroughly reviewing the resume, focusing on the candidate’s experience – this helps reveal whether the experience is genuine or misleading.
  2. Ask about the candidate’s interests, likes, and dislikes. Why did they choose UI? This gives insight into how inclined they are towards computer science and their understanding of it.
  3. Pose targeted questions to gauge their motivation. How eager are they to learn new things and improve their skills?
  4. Technical Round:
    • I start with the basics, such as asking how the internet works. What happens when a URL is entered into the browser?
    • From there, I ask questions about DNS, web servers, TCP/IP, the HTTP protocol and verbs, and their significance.
    • Finally, I move on to technical JavaScript basics, followed by small coding exercises.
    • I always keep the focus on the fundamentals: language basics, ecosystem basics, build systems, etc.
  5. While understanding the basics is critical, I also look for how candidates approach problems they might not immediately know the answer to—this reveals their ability to think critically under pressure.

You might be surprised by how many technical people from reputed organisations, with varying levels of experience, don’t know how the internet works, even though we use it constantly!

What Makes the Best Candidates

I’ve found that the best candidates have a zest for learning new things, the ability to work independently, and a strong grounding in the basics. These candidates often become indispensable to the company. For this reason, I place the most value on a candidate’s attitude.

This approach, however, can lead to precarious situations. You often know within the first fifteen minutes if the candidate is a good fit. The rest of the time is spent prodding and poking to see if anything can be salvaged. Finding a good candidate is difficult. Time spent interviewing equals time invested, doubled. In my younger days, I would often finish interviews in fifteen minutes, telling HR that this would save us both time. However, I quickly realised that there is great value in being humble and well-rounded. Candidates may know some things and not others, but that doesn’t make them bad candidates. They can learn quickly and become good employees. Even if they don’t, it simply means they don’t fit the role we are hiring for – not that they are a bad candidate.

A simple google search will give us a lot of non-engineering graduates and self-taught gurus of many big companies like GitHub, Twitter and Slack.

end.

Enterprise Cloud Software: How small is a small team?

Many startups or small companies have very small teams developing big enterprise products, while there are larger companies having multiple people developing and managing the products. A basic enterprise software has the following functions:

  1. Program Management
  2. Developers
  3. Testers
  4. DevOps
  5. Project Managers

Some of these activities can be performed by people having more than one responsibility. For example, a Program Manager might have a dual role of performing Project Management. Or a Lead Developer can take up the role of a project manager besides leading the team.

A developer most often also performs DevOps activity and in case of an SRE can be responsible for the upkeep of the deployed environment.

It really is about scale and the target of the product being developed. For a small to medium B2B application, a dedicated SRE or DevOps Engineer may not be required. A public facing high volume product, though developed with a few developers, will require SRE or a dedicated DevOps Engineer to manage uptime.

So how do we determine the scale of the team? It really comes down to one thing – Are we assuming that persons in the team won’t take leave or will not have emergencies?

As a project, we should have enough redundancies that the deliverables aren’t affected by sudden absence of allotted person to the role.

Let’s assume, a minimal scenario – we have a Lead Developer and a couple of developers on a B2B solution for a small to medium organization. Assuming the delivery date is 2 months away, It is easy to assume that all the three developers will have a day or two during this time in sickness or absent otherwise. In which case does it impact the delivery date or the quality? If the answer is no, then there are enough redundancies and the team size is good. If the answer is yes, it is obvious that the delivery of the product/project is destined for delay or failure. An Enterprise solution cannot be built on the dependence of a few or on the assumption that people won’t take leaves. Either there will be delays or there will be a tragic drop in quality of the product.

A Developers Productivity Setup using a Raspberry Pi (4)

The Objective

I always wanted to have a workspace that could replace many a tool I use as a paid alternative or tools hosted in the cloud. Specially now, when most of the time I spend at home working, I have a need to manage my productivity. It uses docker for easy siloed management and it does not require any complicated system changes that break one app or the other. Additionally Dockerhub is a treasure of images that can be run very easily and can be leveraged.

The only drawback to using docker as an app deployment tool is that all the tools run in different ports and one has to remember the mappings. The mappings are easily visible in portainer and hence useful. Another useful technique is to locally install nginx and use it as reverse proxy.

NGINX Docs | NGINX Reverse Proxy

Tools Installed

  1. Portainer – Visual docker/container management web app. We will use portainer to deploy containers off dockerhub.
  2. BookStack – Notes taking and writing management tool.
  3. Wekan – A trello like Kanban Board/ Lists App.
  4. Bitwarden Server – To store all my passwords locally and not depend on passwords.google.com or Microsoft. Bitwarden is an open-source solution with a server, web app, browser plugin and iOS/Android apps.
  5. Pihole – To Manage my network and conserve my bandwidth. Primarily an Adblocker and I use this to manage intrusive ads on my parents phones and desktop. This I also use to manage access to devices.
  6. Prometheus/Grafana – Monitor the pi and network.
  7. FileBrowser – To manage additional storage. Simple file manager to manage an attached storage. Simply attach a drive to the pi. Attach it to /srv to mount it to the container.
  8. Draw.io – Diagramming Swiss knife.
  9. PlantUML Server – For UML Diagramming
  10. Hoppscotch – REST/Web Socket Client to replace Postman
  11. Owncloud – Optionally I have a stopped instance of owncloud. I dont really need it as I could do with an old HDD attached to the pi.
  12. Code Server – Code Editor/IDE. The Visual Studio Code Server replicates the desktop app to the web. It provides most of the features the desktop editor provides.

Additionally to the above installation, we get the following as dependencies. This can be leveraged for development:

  1. Mongo Server
  2. MySQL/MariaDB – With Booksstack
  3. Additionally install PHPMyAdmin to manage MySQL.

Also other databases can be installed. Databases like Postgres could be run.


Rasberry PI Preparation

I have tested this in a Raspberry Pi 4gb and an 8gb, it could as well run in a 2gb version, but we may have to reduce the number of containers we host. To run docker efficiently, it is better to use a 64 bit image. I have used the raspbian beta image, however one can choose the ever so stable ubuntu server 64 for raspberry pi.

Installation Instruction follow this guide – Installing operating system images – Raspberry Pi Documentation

Disable the gui from raspi-config – raspi-config – Raspberry Pi Documentation

sudo apt-get update && sudo apt-get upgrade

I have found an issue with dhcpcd when a lot of virtual networks are added:

https://github.com/raspberrypi/linux/issues/4092

sudo nano /etc/dhcpcd.conf
at the end: denyinterfaces veth*

Setup Docker & Docker Compose

wget -O - https://get.docker.com -o get-docker.sh | sh

Install docker-compose:

sudo apt-get install -y python3 python3-pip
sudo pip3 -v install docker-compose

Topology

I have attached the raspberry pi 4 to the router using a RJ45 cable. Much faster as I host pihole. The Pi can be added as a WiFi device as well.


Install Portainer

The Portainer installation guide – Docker – Documentation (portainer.io). Run it in the Raspberry Pi commandline.

docker volume create portainer_data
docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce

Browse to the URL of Portainer. Below is how it looks with containers.

Portainer also has App Template feature that can be used to deploy repdefined stake.


Add App from Dockerhub

In most cases the install is straight forward. Click on Containers -> Add A new container.

Choose an image with ARM 64. In the above example, we are adding an nginx server in the above. Once added to portainer, the env and storage parameters can be changed by looking at the documentation.


Add App using Docker Compose

Portainer accepts docker-compse and many stacks can be deployed using a docker-compose file.

below the compose file:

---
version: "2"
services:
  bookstack:
    image: ghcr.io/linuxserver/bookstack
    container_name: bookstack
    environment:
      - PUID=1000
      - PGID=1000
      - APP_URL=
      - DB_HOST=bookstack_db
      - DB_USER=bookstack
      - DB_PASS=bookstack
      - DB_DATABASE=bookstackapp
    volumes:
      - /path/to/data:/config
    ports:
      - 9080:80
    restart: unless-stopped
    depends_on:
      - bookstack_db
  bookstack_db:
    image: ghcr.io/linuxserver/mariadb
    container_name: bookstack_db
    environment:
      - PUID=1000
      - PGID=1000
      - MYSQL_ROOT_PASSWORD=root
      - TZ=Europe/London
      - MYSQL_DATABASE=bookstackapp
      - MYSQL_USER=bookstack
      - MYSQL_PASSWORD=bookstack
    volumes:
      - /path/to/data:/config
    ports:
      - 3306:3306
    restart: unless-stopped

Custom Install Apps using Docker Commandline

Requires an advanced understanding of Docker.

A lot of tools may not compile due to the images being built with other platform. The moment there is a “process exec” error, it is probably incompatible with arm 64. In which case the best approach is to rebuild from source using an arm based image.

Portainer automatically will pick up any images added or containers launched.

end.

Is it worth buying an Android flagship phone? Or the cost of ownership of a flagship phone.

Flagship phones are premium phones that identify the brand of the company selling it. They are usually built with best-in-class hardware and software. They are also the costliest phones in the market just because they have cutting edge hardware and software which gives them unique features.

Some of the leading brands in the Indian mobile space are Apple, Samsung, Google, and One Plus. Apple uses the iOS operating system and the rest of the brands use Android. Android is widely used for many reasons by the consumers but hardware manufacturers can easily scale up and quickly provide an Apple iOS eco-system like experience. Android also found use in the open-source world providing alternate ROMs for devices and customization. Apps could be delivered through the official Google Play store or alternate app stores like Samsung App store or Amazons app store.- Since it is open, anyone can publish apps with a one-time payment and create adware and malware that can be installed by anybody. Google however routinely bans such apps and publishes security fixes.

The biggest selling point of Android is the price. There is an Android phone at every price point. From an extremely low-end phone which costs a few thousand to phones which costs more than a lakh. There is a market for every price point.

Apple’s iOS on the other hand is developed by Apple as a closed project and the OS works only on Apple hardware. The ecosystem consists of the App store through which apps are delivered. Since everything goes through the Apple review, it is a little bit more secure about adware and malware.

Most of the premium flagship phones would be very close to each other when we speak of performance and hardware. Many though offering different services. Apple offers a consistent experience and provides premium subscription features such as iCloud. Google on the pixel phones offers full resolution/high-quality storage for free while Samsung has a host of services from its own app store to security services.

What is the real cost of ownership of such a premium phone?

  • It is the initial cost one pays for the phone and its services.
  • How long the phone stays new. In other words, how many updates the phone will get.
  • How much will the resale value be after the support ends

All of this by the number of years a mobile phone will be officially supported. After this time the resale value of a phone falls drastically to one third the original price or lesser.

  • Apple supports their software the longest. They provide updates for more than 5 years. This means the phone is bound to get at least 5 to 6 new releases and security updates.
  • Google and Samsung provide 3 years of support, which means after 3 years new builds and security updates will stop.
  • One Plus provides 2 years of support and updates.

From the table, clearly owning an Apple iPhone is better than the rest. The yearly costs are lower than Android phones! We often tend to look at Android phones and think of them to be cheaper. What we are really comparing are cheaper Android phones to iPhone. Hence, it is also more likely that getting a sub-Rs. 30000 phone is a much better value for money than the premium phones at the moment. This is also the reason why all of the 3 companies (including Apple) operate in the sub-30k market too.

end.

Learning Multiple Programming Languages Quickly

Recently I gave a presentation on learning multiple programming languages quickly. The idea of the presentation was to quickly start coding in multiple languages and learn the toughest or the unique parts as we go along practising.

The technique is just common sense though, and has mostly worked for me in my career where I have used it to learn multiple programming languages – Java, JavaScript, Python, Go and Rust to name a few. I intend this article for anybody with interest to learn new languages.

In the hands-on presentation, I presented ways to understand Go, Rust and the newer Nim quickly.

Before we start:

  • Basic knowledge of Programming – Differences between Object Oriented concepts, procedural programming and some previous experience in some programming language.
  • Go and Rust are systems programming languages, which require the knowledge of knowing the internals – particularly network, multiprocessing, memory and other things you wish to use it for. Other languages like JavaScript requires the knowledge of understanding the Web and how various parts of the web work. The more general-purpose the language is the more specific becomes the knowledge – Python can be used for many types of apps and libraries, hence it is important to know fully the consequence of what you want to achieve.
  • The most important aspect to a developer is maintaining the history of the changes made, hence on the way, knowing how git or any other source control tool works will be a great plus!
  • Interest and time is of prime importance. If you have an interest you will make time!

Usually, any programming language has a learning curve. The lower the language is, the harder it becomes. Ruby or Python, for example, might take a week compared to C or C++, which can take weeks. If it takes that long to learn any language, why not learn more than one?

It is essential to pick conceptually similar languages. For example, if you are learning Ruby, Python becomes easier. If you are learning JavaScript, then mixing it with learning TypeScript or Lua can speed the understanding. It also helps compare the features and remember better.

This blog is also no about mastery in learning multiple languages. Mastery takes years together. This is about learning just enough to start coding meaningful stuff quickly.

There are few things common to every language –

Eco System

Eco-System is about how to build and ship. Every language has a source build system, a way to ship for distribution and tools to help build everything.

  • Java has the javac compiler, jars for distribution and the JVM for the runtime.
  • Similarly, python has a runtime installation for running python scripts. IT also has tools like egg and wheel for distribution.
  • Go, and Rust produces system binaries that can run natively without a VM. Go binaries are usually bigger as it compiles a runtime into the binary. Rust has a bare minimum runtime – the coding style itself helps to manage the memory and other safety.
    • Rust has Cargo to create, manage and compile projects, while Go has “go tools” to do something similar.

Defining Functions

Every programming language has a way to declare code blocks, provide an entry to run the code. Keywords such as func, def, fn are used to declare blocks of code.

Additionally, special blocks named “main” exists in many languages, including Go, Rust, C/C++. While Python and Nim, the body of the file itself is the main function.

Decision Making & Looping

The most important part of any code is decision making and looping. Every programming language has tools to enable decision making and looping.

Go handles looping using the for keyword itself for looping over a range, dictionary or sequence. Rust has for loop and while loops similar to many other languages.

Memory Allocation

This is probably the most complex part of a programming language – How to declare a variable, how to destroy after the usage. Higher-level languages use different techniques such as garbage collection and other methods for automatic memory management. Lower-level languages like Rust use several language constructs to help with allocation and deallocation – particularly mutability, ownership and borrowing and lifetimes. Go has a garbage collector along with pointer constructs to offer for managing memory efficiently.

Source Structure and Modularisation

Modularisation and dividing similar functionality, albeit being not as important as others are of deep importance. Languages like Java enforce it by the way code is written into directories. This affects how reusable code is imported and shipped. Rust has modules and cargo for the same purpose while Go borrows a little bit from java. Go also has a specific $GOPATH which makes it a good practice to develop sources in a specific location.

Other Things

OOPS is different in each language. Java is considered a pure Object Oriented Language while JavaScript has a prototype-based inheritance. GO may or may not be called OOPS and Rust is only interface implementation based object-orientism.

Every time I have to learn a new language, I approach them not only with understanding these 5 concepts, but also by writing code and using aspects of those. Here are the example I used:

Factorial in Go
Factorial in Rust
Factorial in Nim

end.

Companies should be responsible for what they produce.

We are killing ourselves and our children. We have about twenty years. Climate change is real.

There are so many mobile companies in India cashing in on the mobile craze. There are at least 500 million users in India and it is only growing. It is at least less than half of India’s population.

Given the life of a mobile phone on an average is about 2 years, where do all the old mobiles go? A fraction is recycled through second-hand selling and unlike cars, the sale is limited given the number of options available to the consumer in India.

Batteries, boards and so many chemicals go into landfill. It is toxic and detrimental to the environment.

If a company produces a phone, they should have a plan for it to be recycled and destroyed naturally after its EOL and longevity in the market. If a company wants to produce a product they should naturally be responsible for its end. After all, they are invested in the phone being in the hands of people and earning money from the ecosystem. The time they did something for the real ecosystem.