Write a short program that prints each number from 1 to 100 on a new line.
For each multiple of 3, print "Fizz" instead of the number.
For each multiple of 5, print "Buzz" instead of the number.
For numbers which are multiples of both 3 and 5, print "FizzBuzz" instead of the number.
The above text is what we call the FizzBuzz problem in the world of programming interviews. This ‘simple’ question has been around for a long time.
It seems pretty easy, right? I thought so too! I had seen FizzBuzz around but had never actually given much…
It was early December of 2020 when I began to feel discomfort while sitting down during work. It was then that I noticed that there was a cyst on my left glute. At first, I didn’t make much of it because I thought that it would just go away. Guess what? It didn’t go away.
After a week of dealing with the pain, I finally decided to go to the Doctor to get it checked out. I’ll admit that it felt weird when the doctor asked me to lie down in order to take a look at the cyst. To…
Take a look at the code below. Do you see anything wrong with the
NavBar component? You might even want to play around with the results if you cannot find the problem by simply looking at the code:
If you answered
Developers often write test cases along with their code. On top of that, they even add some exploratory testing to their work pipeline. However, sometimes, there are some errors that escape their well-thought-out testing processes and end up in production.
A lot of these errors are experienced and discovered by the end users — some of them might report the problem, some might try later, or some might outright reject the product because of the error.
Thus it is important to be able to quickly react to errors that occur in production. It’s easy to debug and fix an error…
The above chart shows the price over time of a cryptocurrency that went from a little over $450 down to nothing in no time at all. This cryptocurrency is non other than BitConnect — which is probably the biggest scam ever in the history of cryptocurrencies.
The value of Bitcoin is rising again. This means that it is a good time for people to run scams because there will be a lot of new people in the crypto market. …
Those of us who have worked with functional components in React know that the introduction of Hooks has made our lives a lot easier. However, functional components have their own set of complexities and gotchas. As a result, it can sometimes be difficult to write readable and optimized functional components. Today, we will look at five simple tips to help us do just that.
Let’s take a look at the following React component called
This component takes an array of items, sorts them according to the comparison function provided, and displays them. However, this sorting operation could take…
Working with time zones can be rough! In fact, this article was inspired by the problems that I had with them. I finally decided to bite the bullet and do some extensive research to properly understand them. I found that they get much easier to work with when you understand the basics. This is my attempt, by putting all the basics in one place, to help anyone else who is struggling with time zones. There are also solutions to some common problems at the end.
This is the first thing we need to understand before looking at time zones. UTC…
Are you a React developer? Do you use Hooks and functional components? Do you use ESLint to ensure your code does not do anything spooky? If yes, then I am sure that you have run into the
exhaustive-deps ESLint warning while using
So, this happened about half a year ago. I was in a cafe which I frequent and I was having a pee-mergency! This place has two restrooms; one on the left and one on the right. I always went to the left side because I had never seen another male go to the right one and because ladies are always right. Yeah, I stole that last line from a clever sign I have seen at restrooms in multiple bars. Anyways, I have no idea why the guys always go to the left one in that place because none of those…
Pull Requests (PRs) are a major part of any software development team that involves multiple developers. They help us better compare and track changes in the code. However, I have seen that a lot of software development teams completely ignore one of the most important advantages of PRs: Code Review!
But who even has time for Code Review right? Merging your PR as soon as you push it and continuing on with the development process is so much easier! This is exactly what I used to think when I first entered the world of Software Development. I would just push…
Technology for Passion, Noodles for Hair and Junk for Food