How do computers translate everything to binary? When they see a binary code, how do they know if it represents a number or a word or an instruction? -


I know that computers translate numbers into binary but what I do not understand is that I Have heard that computers translate everything (words, instructions, ...) into binary, not just numbers. How is this possible?

Can you show me some examples? Like a computer translates "A" to binary?

And when computers see a binary code, how will they know that the long string number of 0s and 1s represents or the word or direction

. Exemple:

We say that a computer programmer encoded the "Z" letter so that he translates this binary string: 11011001111011010111

So when the computer has this binary string If he has to face, then he will translate it into "Z" letter.

But when we ask this computer "What is the product of 7,9125?"

The computer will respond to us "892631". But that number, when translated into binary, is 11011001111011010111.

So how can it make a difference between "Z" and "892631"?

Please note that I do not know much about computer science, so please explain everything in simple words.

Computer actually does not translate anything to binary, it is all binary from the beginning, and Do not know anything other than computer binary.

In the character, A will be stored 01000001 , and the computer does not see anything except a binary number. When we ask the computer to display that number as a character on the screen, it will look at the graphical presentation for it in the font definition to find some other binary numbers for the screen.

For example, if the computer was an eight bit attic, then there would be eight binary values ​​to display the A character on the screen: <00p>

As you can see, binary values ​​will then translate into dark and bright pixels, when the graphics hardware will attract it on the screen.

In the same way, whatever we do is, in the computer, with numbers, it has all the ways to move binary values ​​around calculating binary values, and translating into other binary values.

If you want to display A for example and as a decimal number, the computer will calculate that decimal representation of number is gits 6 ( 110 < / Code>) and 5 ( 101 ), translate that character to 6 ( 00110110 ) and translate it to character 5 ( 00110101 ), and then translate those people into their graphical representation.

Comments

Popular posts from this blog

php - PDO bindParam() fatal error -

logging - How can I log both the Request.InputStream and Response.OutputStream traffic in my ASP.NET MVC3 Application for specific Actions? -

java - Why my included JSP file won't get processed correctly? -