In my previous article, we saw about the bottoms-up approach or tabulation to solve problems. In this article, we are going to pick the same problem of calculating the nth fibonacci number of the fibonacci series using another technique called, top down approach.
Like how in the bottom-up approach, we went to the bottom of the problem and solved for the sub-problems before landing on the solution of the main problem, the top-down approach is just the opposite of that. But if it’s the opposite, then are you saying we will start with the solution of the problem? Well! …
Understanding the nuances of Python namespaces and scopes is often helpful to make wise decisions when writing advanced Python. Python is such a friendly language that, it lets us break the rules easily and yet achieve our goals. But, sometimes rules broken in the past could come back to bite us in the future in unimaginable ways.
A Namespace is a mapping between variable names and objects. There are 3 general kinds of namespaces:
In this article, we are going to learn the most basic and fundamental technique of Dynamic Programming(DP) called Tabulation or bottoms-up approach.
Any large computer science problem can be broken down into smaller sub-problems. These sub-problems can be independently solved and composed to get to the solution of the main problem.
Take for instance the problem of building a house from scratch. At a very basic level, the house is just a unique arrangement of bricks assembled with other raw materials. Each brick requires the exact same amount of effort and same technique to produce it. …
Netflix’s co-founder, Marc Randolph’s episode on the Tim Ferris show is full of interesting stories and nuggets from the origins of Netflix. I will try to paraphrase a few of them which I found interesting:
“There is no such thing as a good idea. Every idea is a bad idea. Crazy ideas that might have been Netflix: “
“Prediction” of technological change in the strict meaning of the term would require ability to know both what changes could be expected and when they would occur. We can know with high probability what technological changes are likely by looking at a few dynamics
The first dynamic element in technology is economic needs and opportunities — Declining productivity of capital in a major industry. …
The card networks(VISA/MasterCard) started out as non-profit associations helping their member banks to generate profits. Today, they are hugely profitable publicly traded companies — A fact that would have astonished anybody in the 80s. How did this come to be? Read further
It’d be a stretch to say that the card networks might not exist today had the Federal Reserve Bank not mandated the banks to accept checks for deposit at par. But, this certainly took away the profits banks would have otherwise made by charging check deposits. The Checking account is by far the oldest payment system in the…
An interactive 2FA screen is table stakes with the SignUp/SignIn flow these days especially if you’re building an app that requires high levels of security.
Note: If you came for the code, skip to the bottom of this post for a link to my GitHub repo.
In this post, I will walk you through the process of building a screen that looks like the one above. So let’s get started.
For the animations part, we are going to use a third party library called animated widgets which you can find here: https://pub.dev/packages/animated_widgets
So, let’s go ahead and declare it in…
In this post, I am going to explain what problems GraphQL solves, setting up of a basic GraphQL project using graphql-express, what are root types and how to best structure the code in GraphQL projects.
If you’re a REST aficionado like me and you are hearing a lot of buzz around GraphQL, then you’re not alone.
GraphQL will do the “REST”
— Someone on Twitter
Before jumping into conclusions with no data, I decided to unravel the mystery of GraphQL by diving deep and tried to understand how different it is from REST.
This post is structured as follows:
So let’s get…