Null vs Undefined

Okay, let’s make it fun!
I hope this way will make it stick to you.

Variables are like the remote controls in JavaScript that control the objects.
So, when a proper object cannot be assigned to a variable JavaScript says “Hey you, your remote control is not programmed to control any of my objects. I am tagging your remote control (variable) as ‘undefined’ “.

1. var x;

2. console.log(x);

3. => undefined

So, Undefined is a special type, whereas ‘null’ is an object in JavaScript.

1. console.log(typeof null);

2. => object

It is a special-purpose object that…

Difference between Framework and Library — A library usually focuses on a narrow scope. It provides a set of helper functions, methods, etc which you can call in your project to achieve specific functionality. It’s basically a collection of class definitions that is written mainly to promote code reuse. There’s no need to start from scratch every time, you can easily use written by others to save time and energy. As Library has a narrow scope, the APIs are also smaller and ultimately the project requires fewer dependencies to get things done.

Whereas, Frameworks are like the foundation on which…

Exceptions -

Coding is something that is not definite. This means it is very unlikely to smoothly run through all the way to the output unless you are exceptions. Every developer, programmer faces error while developing something. While getting errors you must be out of your mind after seeing a bunch of lines in red, indicating something you are almost unaware of. There comes Error handling to gently handling all the error and make a statement about what exactly the problem is about. Almost every modern language has these exception terms handled in the same way and JavaScript is indifferent to it.

Today we are going to skim through built-in methods which are frequently used in javascript programming. Don't miss to go through all the way as there a surprising knowledge at the end ;)

Some of the basic built-in String Method in JavaScript–

charAt()— It returns the character of the given index. Note that, All the string index starts from 0. Therefore, character = string[index-1]

Example –

var name = “shuvo”;


returns => s.

concat ()— It basically combines any string, character, number or any sort of data having no gap.

Example –

Var a = “Appl”;


returns =>…

MD. Razaul Haque Subho

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store