# Archives August 2018

## Asymptotic Notations – II

In this post, we will see the remaining two asymptotic notations. The algorithm we were discussing was the linear search. We had calculated the estimated time complexity as 2n + 3. To read the previous post, click here. Big-Omega – The Lower Bound function f (n) belongs to big-omega of g (n) if there exist

Read More

## Asymptotic Notations – I

In this post, I will discuss the time functions in asymptotic notations. You probably have heard about asymptotic notations. They are the Big-Oh, Big-Omega, and Theta functions. I had read in details about them when I was in doing my B. Tech [I couldn’t recollect which semester, and that is a pity]. It is going

Read More

## Why do Exponential Functions Hurt?

Before we move further, let us recap the types of time complexity functions we have encountered till now. We will also see that algorithms with exponential functions are evil. Here is the list of functions we have seen till now. The sequence of these functions is the same as written above. That is, a quadratic

Read More

## Time & Space Complexity – IV

In this post, I am going to talk about the time complexity of one more type of algorithms. Once again, we do not need to discuss the space complexity as it is going to be the same as all the other for loops. In the previous post, I had given a small introduction of logarithmic

Read More

## Basics of Logarithms

Before we move to the time complexity of the next algorithm, I’ve decided to give it a break and write a short post about logarithms, they are crucial. I’ll be honest, and I’ll confess that I always had a hard time understanding the concept of logarithms. While working with time complexities of the algorithms, we

Read More

## Time & Space Complexity – III

In the previous post I talked about time complexity of simple for loops. In the previous post, I talked about the time and space complexity of simple for loops. I hope you got the time and space complexity of the algorithm with 3 for loops as O(n^3) and O(n^2) respectively. Let’s discuss some more examples,

Read More

## Undefined Vs Null

In JavaScript, both undefined and null come under primitive data types. But they are not as simple as a string, number, and boolean. A variable is said to be undefined when it has been declared (for future use) but has no value assigned to it. For example, Line 2 prints undefined in double quotes, i.e.

Read More

## Data Types in Javascript

JavaScript is not strict when it comes to data types and use of variables if we are writing codes without using ‘use strict’. None of the code example in this post has been written with ‘use strict’ option. As a result, we can use a variable (without declaring it) and the JavaScript engine won’t have

Read More

## Creating a Highlighter in Vanilla JS

I think thrice in recent past I needed a highlighter while coding. Two times, I used the plugin. Once the jQuery plugin, and the second time, a react plugin. Then when I was creating a filter (by the way, filters are my favourite), I needed the highlighter once more. I opened a new tab in

Read More