Welcome to our new lecture
In last lecture we have studied about number system
We have seen a brief about it What is number system
And why we need to learn it As a programmer I should know
How things are converting
From high level language
To low level language
How things are converting
However We don't need to do these things
It compiles on our behalf
But still
For these things
You should have some idea
That You are a programmer
You are going to write everything
You know
It can be an invention
You should know
That this is my low level language
This is my machine code
This is how it works
We have seen examples of high level languages
C++, Java, Python
We have seen all these things
Today in this lecture
We are going to see conversions
We will see many examples of conversions If you know things
in decimal
Then you can convert it in binary You can convert it easily
Our decimals
Converts in octal And our decimals Converts in hexadecimal
Why it happens Many times we are not able to remember these
things
For example
I gave you a big number
I said 2560 Tell me the binary of this number You can
convert it easily
But It is not easy to remember
I can convert it in octal
I can convert it in hexadecimal
So this number system
It is for this reason
Let's see
We will talk about
How our data Is stored in memory
In which form We will talk about it
So that you can have an idea I know
It is stored in 101
But how exactly it is stored
There are some units of memory
We will talk about them
Let's open the whiteboard
And see what we are going to see
And how we are going to
Measure it
The first thing I see
That is a computer memory unit
What does it do
What does my memory unit do
As we measure anything
There are units to measure
In the same way
To measure you How your data Will be stored in memory
Some units are made for its measurement Let's read it What
things are written here
The first thing Memory units
There is a concept like memory units Memory unit is the
Amount of data That can be stored in the storage unit
Which means
Whatever your storage is
Whatever your data will be stored in it
Now your data If I talk about programming
Either you store the number
You can say What is 10 plus 20
What is 10 plus 20
What kind of data is this
This is the data of integer type Or you can say
Do one thing 17.5 Plus 10.6 What kind of data is this
This comes in points
This is your float number
This is also A different type of data
If integer number Like in integer number
I said 175768 175768 You have to store this number
There is a limit in integer
You can do only this much number There is a different
format for this Long data type Or I said Store my name When
you see google form
When you fill the form
You put your full name
How to store Rahul Rohilla How to store
R Equivalent Equivalent Equivalent Equivalent Equivalent
Equivalent Equivalent Equivalent Equivalent Equivalent
Equivalent Equivalent Equivalent
Equivalent Equivalent Equivalent Equivalent Equivalent
Equivalent Equivalent Equivalent Equivalent That in which
Storage capacity is expressed
In terms of bytes
Main memory storage unit
Bit Binary digit
Logical 0 and 1
Representing Passive or active state
Of component in electric circuit
For example
Electric circuit
The data stored is of the fan
ON ON ON ON ON ON ON ON ON ON
group of 4 bits is called nibble means there is a group
which has 4 bits now try to understand what is there in
here there is a bit and this is a binary digit now let's
come to nibble, now understand a group of 8 bits is called
byte a byte is smallest
unit which can represent a data item or a character means
data is stored in the form of byte now try to understand, I
said that I have written here integer
a equals to 4 means how my 4 will be stored in memory and
you have to remember that what is the smallest unit? it is
byte and how much is there in 1 byte? in 1 byte there are 8
bits
ok so the data stored in the computer is in bits means how
many bytes does our integer take? 4 bytes, so it means we
will make a box like this 1 2, 3, 4 5, 6, 7 ok, so total is
8 boxes what is this? 1 byte and what is this? 8 bits 1, 2,
3, 4, 5 6, 7,
8 means what does my 1 box represent? it represents my 1
bit now how will the data be stored? try to understand so
what will we do with 4? 4 is a decimal number what will we
have to do first? we have to convert it we have to convert
it to binary it is
very easy, we have done it before
then we will divide it by 2
I have divided it by 2 it is 2, so how much is the
remainder? 0 then I have divided it by 2, so how much is
this? 1, so how much is the remainder? 0 then I have
divided it by 2, so how much is this? 0 now I will write it
from bottom to top so I will say
that the 4 which is given in decimal after converting it,
what comes? 1 double 0 and here comes 2 this is the base
unit from which I get to know that the number which is
written here is given in what? now you will say that
I got to know 100, you told me a shortcut write it like
this 1, 2, 4, 8, 16 32, 64 write it like this 4 write 1
here write 0 here, 0 here write 0 here, 0 here
3 4 5 6 and 7 this is 8
I have made one more like this so this is my number
I will represent the byte sorry I will represent the bit 1
2 3 4 5 6 7 and this is my last
I have made one more this is my 1 2 3 4 5 6 7 this is my
one byte this is my one byte this is also my one byte ok
and this is also my one byte so total I have it tells me
that my number where is my number where is my number here
it is 1 2 5 7 6 it tells
me that what is this number this is decimal number and it
tells me that integer takes maximum 4 byte 4 byte means
like this 1 byte has 8 bits like this is 1 byte and this
has 8 bits then I have one more byte and one more byte so
now see this hypothetical
will be stored like this 0 0 0 0 1 1 1 1 1 double 1 0 1 0 1
rest will be like this 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 one second
we will start from here, from number conversion
so we will hide it
and we will start from number conversion let's see how it
is working
but number conversion will be done in next video we will do
it in a fresh way let's see what we have done we have seen
the memory units in memory units we have seen that the data
can be of different types it can be of different data types
according to
that they take space some take 4 bytes, some take 8 bytes,
some take 16 bytes and the data which is represented in
memory is in data 101 but it is like this that one byte
boxes are made of 8 bits and it is stored there and the
starting bit is the most
significant bit here what happens is here comes the sign
like plus number or minus number so this represents 0 or 1
we have seen that there is a character name what is its
equivalent you will get to see a decimal number and you can
convert that decimal
number easily we have seen that there are some memory units
which are 2 nibbles in 1 byte 8 bits in byte, bit and word
computer stores the data in word form after that I have
seen that in 1 kilobyte there are 1024 bytes in 1 megabyte
there are 1024 kilobytes
in 1 gigabyte there are 1024 megabytes
MB in 1 terabyte there are 1024 GB in 1 petabyte there are
1024 TB
I hope you like this video if you like this video please
share it with your friends like this video and comment us
I will meet you in next video with new topic till then good
bye
to your friends and they sign up using your referral code
you'll get some awesome rewards that sounds interesting you
earn points that you can redeem for discounts or even cash
rewards and also get the job guarantee after completing
course count me in
I'll make sure to spread the word to all my classmate