Skip to main content

Why Variables and Data types are required?

Writing a program means playing with data information. Performing operations on data. And remember no any programming technology performing any operation on data actually. It is a processor's ALU unit which is responsible for operations. ALU fetch data from RAM, perform operations and store back the result on RAM. That's why operators are the same in every programming technology.
RAM made up of cells. and every cell has the size of one byte which is identified by a unique address Nowadays, there is RAMs are in gigabytes i.e. billions of cell on RAM. So much lookup time to find the values on RAM.

To optimize this lookup time Programming technologies reserve some space for themselves initially. When Any Programming technology requests to the processor for some operations on its values. It also specifies their unique names with the request. These names bind with the address of cells internally where values are stored. This will help to find the values immediately. This name is known as Variable Name.

 Variables are name of memory location.
But still, there is one problem to resolve. Data can be a number, alphabet, string, symbols or true/false. Different type of data takes a different memory size. The processor needs to know already that which kind of data is coming to the store. because it has to reserve memory for variables before storing them. So when we request to the processor to store the values we also tell the type of variable as Integer or String etc. These are called DataTypes 


  1. The Venetian® Casino Resort in Las Vegas, NV - MJH
    Plan your next event or meeting at The 남원 출장샵 Venetian® Casino Resort in Las Vegas, NV. 고양 출장안마 Check 삼척 출장안마 out total event space, meeting 부천 출장샵 rooms, and request a 영주 출장마사지 proposal today.


Post a Comment

Popular posts from this blog

Why "F" and "L" suffix | (10.0F, 10L)

Let us take it this way, We will create their needs. So we will get why they are needed. Try to guess, which functions will be executed in the following program: public class MyClass {     public static void main(String args[]) {         MyClass obj = new MyClass();         obj.fun1(10);     }     void fun1(byte val){         System.out.println(val);     }     void fun1(int val){         System.out.println(val);     }     void fun1(float val){         System.out.println(val);     }     void fun1(long val){         System.out.println(val);     }     } It seems like every method is capable to run this program because 10 is still literal because It has no data type. Before Java, In previous technologies, this scenario gave an ambiguity error. But Java solves this problem by removing the concepts of literals. It means Java provide a data type immediately when these born. So here 10 is no more literal. Java provides Integer data type for it. So now it is of Integer t

only large files upload on S3 | Ruby On Rails

models/attachment.rb class Attachment < ApplicationRecord after_initialize :set_storage private def set_storage # larger that 5mb file would be upload on s3 if file . blob . byte_size > 5_000_000 Rails . application . config . active_storage . service = :amazon else Rails . application . config . active_storage . service = :local end end # end of private end

Promises and Async-await in depth : Asynchronous Programming in Javascript

Promises and Asynchronous Programming One of the most powerful aspects of JavaScript is how easily it handles asynchronous programming. As a language created for the Web, JavaScript needed to be able to respond to asynchronous user interactions such as clicks and key presses from the beginning. Node.js further popularized asynchronous programming in JavaScript by using callbacks as an alternative to events. As more and more programs started using asynchronous programming, events and callbacks were no longer powerful enough to support everything developers wanted to do.  Promises  are the solution to this problem. Promises are another option for asynchronous programming, and they work like futures and deferreds do in other languages. A promise specifies some code to be executed later (as with events and callbacks) and also explicitly indicates whether the code succeeded or failed at its job. You can chain promises together based on success or failure in ways that make your code easier t