# Thoughts on Odisha!

When I met people outside Odisha mostly in north India, believe me, most of them don’t know where exactly Odisha is. They will simply say “ somewhere beside West Bengal”. They are even confused between Odissi & odia . They think Odissi is our mother tongue.

• Firstly, most non-Odia pronounces Odisha as Udisha. Guys, it’s “O” not “U”
• Secondly, In 2011 the name of state Orissa became Odisha. So stop calling Urissa.
• I think it’s a nationwide belief that Odisha is the most poverty-stricken state. It’s a huge misconception…

# The midnight shayari!!

I Was travelling in a cab around 4 am in Punjab and started chatting with the cabbie! He told me that he shifted to Punjab from Pakistan about 6 years back due to some family feud back home.

The conversation shifted from small talk to me asking him about his education and his plans for the future. He told me that he completed his B. Ed and was unable to complete his final Master's paper. Even without me asking him, he told me that he was too much interested in Shayari too.

I pressed him to share some of his…

About a decade ago, I was given three choices: Science, Commerce and Arts. A passive kid, I picked science. After all, it’s what everyone does.

Two years later, I found myself applying for colleges. Irritated that I had to think and choose again, I looked at the most popular options.

1. Computer Science
2. Electronics and Telecommunication
3. Mechanical

Wonderful. I copied it onto my application form.

I knew nothing about computers, save for Age of Empires and FIFA. With little exposure to the outside world, I had a romanticised view of ‘passion’ and ‘brilliance’. If this failed, I could always excuse myself…

# Solving Coding Problem: Best Time to Buy and Sell Stock

Given an array of integers where the ith integer represents the price of the stock on day i, return the largest possible profit from completing one transaction (i.e. buying 1 share and selling 1 share).
Examples: Given the following prices…

`// Buy on day 1 and sell on day 5 for a profit of 5 - 1 = 4. prices = [1, 2, 3, 4, 5], return 4. // Buy on day 4 and sell on day 9 for a profit of 11 - 1 = 10. prices = [4, 5, 2, 1, 6, 10, 4, 9, 11], return 10…`

# Binary Search: Is this food hot enough for my consumption?

Let’s talk about a classical computer science algorithm and how it can help you avoid getting burned or your jaws mutilated from teeth chattering on a cold morning. It can also help you quickly find words in a dictionary (if you still have one lying around), and solve many other daily life issues with minimal effort.

We’ll use searching a word in a dictionary as an example. Searches often have a “search space”, which are the confinements of where our answer could be. At the beginning, the whole dictionary is our “search space”. Our aim is to keep reducing this…

# INTERNSHIP PROJECT

Hackerrank, 2019.

My friend was drawing on the board while I looked on. We were in different teams, each assigned a project. His program currently took 5 hours to execute. The requirement stated one hour. As the ‘algorithm enthusiast’, I was called for help.

The program was to find the friends of all users in a social network. After explaining the use-case, my friend showed me his approach. I was very determined to find an optimization, hence I did. Immediately.

“An adjacency matrix?! No, use an adjacency list. The execution time will reduce in your case to O(N). Or you…

# Design Reddit: System Design #1

Imagine you’re the engineer responsible for building Reddit from the ground up. Walk me through how you would design the system to support the following functionality:

## Requirements:

• Users can make posts in different forums (i.e. “subreddits”)
• Users can attach images to their posts
• Users can upvote or downvote posts
• Users can see a feed of posts sorted by ranking or recency

## Constraints:

• We want to support a large volume of users (millions) viewing and posting content

## Hints

Think about the core components that you’ll need, and then dive deeper into them. What kind of database would you…

# Summing Root To Leaf Numbers

Sum Root to Leaf Numbers is an interesting problem from LeetCode. The problem is of medium difficulty and is about binary trees. This post is an explained solution to the problem.

I assume that you’re familiar with Python and the concept of binary trees. If you’re not, you can read this article to get started.

# Solution: Find the center of the maze

A man starts from the north-west (top-left) corner of the land and begins walking towards the center of it, in a spiral manner. As the man moves, he keeps track of the number of trees growing on each block of land and records the counts on his journal until he reaches his destination. This list of numbers is the key to unlock treasures hidden there.

You need to be faster than him. Satellite imagery has already provided you the count of trees on each block of land. …

# Solution: Two Sum

## You’re given an array of integers. Write a function that returns a pair of numbers such that they sum up to zero.

You can assume there will be exactly 1 solution. Each element in the array can only be used once.

Example:

`Array of integers is [2, 7, 9, -2].The pair that sums up to 0 is (2, -2).`

Input:
A list of numbers, separated by space.

`2 7 9 -2`

Output:
2 numbers from the array that sum up to 0.
We will sort the 2 numbers for you so that you can easily compare with our expected output.

`-2 2`

# Observe

1. For a number A, we want to know if such a number B exists, such that A + B…

## S7rthak

Software Engineer @Vedantu, Former Intern @Hackerrank, GSoC @Wikimedia, Codeforces(Expert)

Get the Medium app