And of course, computers didn't just use bytes for encoding and processing integers.
They would also often store and process human readable letters and numbers and these called characters.
And early character encodings such as H.
CII Ascii had settled on using eight bits per byte.
But this gave only a limited set of 128 possible characters.
Now this allowed for encoding English language letters and digits, as well as few symbol characters
and control characters, but could not represent many of the letters used in other languages.
So the ABC, a, e, b, C, D, IC standard using its eight bit bytes, which you learned in previous
lecture.
Choose a different character set entirely with the code pages for swapping to different languages,
but ultimately these characters it was too cumbersome and inflexible.
So over time it became clear that so we.
This was the first version Ascii.
Sometimes Ascii is still using, but not much.
And after that, over time it became clear that we needed a truly universal character set supporting
all the world's living languages and special symbols.
And this culminated.
Dominated, as I can say that supporting all the world's living languages, and this created a U, T,
F or Unicode project.
First, let's start with the Unicode.
So Unicode universal code.
This is the Unicode project uh in 1987.
Now a few different Unicode encodings exist here.
But the dominant encoding used on the web is you eight.
You have like 100% encountered this when writing a document on word or LibreOffice, so characters within
the Ascii character set are included Verbatim in the UTF eight, which is extended characters can spread
out over multiple consecutive bytes.
Now, since characters are now encoded as bytes, we can represent characters using two hexadecimal
digits.
Remember, one byte equals to one hexadecimal digit.
So as the UTF eight is two bytes, we can fully represent the UTF eight in a two hexadecimal digit.
So, um, we can represent characters using two hexadecimal digits.
And for example, the characters a.
Let's actually use R and let's say m.
So these characters are not normally encoded with the octets here.
So a a is zero x 41, r is zero x 52 and m is 0X4D.
Now this zero x.
This means this is a hexadecimal.
And the each letters in UTF I said has two hexadecimal numbers since they are two bytes.
Now each hexadecimal digit can be encoded with a four bit pattern.
So one byte four bit ranging from 0.0.0.0 and 1111.
So in the A here.
Four and one is what four is 0100.
You have learned that in previous lecture and one is 0001.
So this is a full A in a hex UTF eight.
And so in R what we have in R we have uh the five is what 0101 and the two is zero two.
In hex is 0010.
So this is a full character.
And we also have the 4D4 and D in hexadecimal.
Uh four in hex is 0100 and D in hex is 1100.
Now 1101.
And that is a full UTF eight character as well.
Now, since two hexadecimal values are required to encode an Ascii character, eight bits seem like
the ideal for storing text in most written languages around the world, or a multiple of eight bits
for characters that cannot be represented in eight bits alone.
Now, using this pattern, we can more easily interpret the meaning of a long string of bits.
Now, um, let's use some text here.
So this bit.
0100000101.
010010.
So.
Yeah.
And 1101.
So I'm asking you In UTF eight.
What these bits stands for.
So we will divide it so we know that UTF eight is.
Oops sorry.
So we know that UTF eight is basically what using eight bits which is two bytes or two hex.
So this here means oh this looks familiar right.
So this means here a.
Yeah.
This means here.
Ah.
And this looks familiar to.
M so in bits we have basically written a thank you for watching and I'm waiting you in the next lecture.