About the Expression and Processing of Data in Computers

Erdeniz Tunç
4 min readApr 13, 2023

--

This article includes:

  • Terminology
  • Expressing Data on Computer
  • How Does the Computer Understand the Typed Code?
  • The Process of Converting Java Code to Machine Language

In this article, I shared my notes that I combined while doing research on how data is expressed and processed on the computer. I mentioned that computers store, process and manage data using binary numbers (0 and 1), which is the basis of machine language used in electronic devices. I stated that bits, the smallest data unit, are used to store data in computer memory, and larger units of information such as bytes, megabytes, gigabytes, and terabytes are formed by combining these bits. I explained that in order for the programming languages to be understood by the computer, the codes written must be converted to machine language and this conversion is done through tools such as compilers.

Terminology

  • Assembly: Assembly, one of the programming languages, is a lower-level programming language that is close to machine language. Programming languages that are close to human language are called high-level programming languages.
  • Machine Language: Machine Language, which is the most basic programming language that the computer can understand, is expressed with a binary number system consisting of zeros and ones.
  • Binary Numbers: Binary, the number system using two values (0 and 1), is the basis of machine language used in electronic devices.
  • Transistor: Transistor, one of the semiconductor components used to control signals in electronic circuits, forms the basis of the working principle of computers.
  • Bit: Bit, which is the most basic data unit of the computer, is the smallest data unit that can take the values of zero or one.
  • Byte: Byte, an 8-bit data unit used to store data in computer memory, is widely used for encoding characters and measuring file sizes.
  • Bytecode: It is a platform-independent intermediate language by compiling Java code. It is formed with the Binary (0 and 1) system that it creates instead of machine language and is interpreted and executed by the JVM (Java Virtual Machine).

Expressing Data on Computer

Data (Picture, video etc.) is stored and processed electronically on the computer. It uses binary numbers (Binary Numbers) consisting of Bits (0 and 1) to process data on the computer. Computers can process, organize and manage this information through software such as operating systems, application software, and databases.

The bit is called the smallest unit of since. The numbers 1 and 0 (bits) in the binary number system show whether the transistors used by computers for electricity transmission are on or off. Transistors have two commands. 0 (close) and 1 (open).

Computers combine these bits to create larger units of information, bytes, and then larger storage units such as megabytes, gigabytes, and terabytes. These volumes are terms used in computer storage.

How Does the Computer Understand the Typed Code?

We write any programming language, eg C#, Java through platforms like Editor or IDE. Code written close to human language is first compiled and converted into machine language (0’s and 1’s) for the computer to understand. Since the language of the computer is the Binary number system consisting of 0 and 1, it reads and outputs.

The Process of Converting Java Code to Machine Language

  1. The code you write in Java is compiled with the Java Compiler, which Java already has, and creates the Bytecode file with the .class extension.
  2. Bytecode file with .class extension is specific to JVM (Java Virtual Machine). Our processor cannot process it because it cannot read at this stage.
  3. JVM (Java Virtual Machine) converts .class extension bytecode to machine code by processing line by line and runs it.

Bytecode is Java code compiled into a platform-independent intermediate language. It is formed with the Binary (0 and 1) system that it creates instead of machine language and is interpreted and executed by the JVM (Java Virtual Machine).

In summary, the prosess is:

Java → code compiled → converted to bytecode → converted to machine language → execution

The sample image has a more detailed version:

Summary

  • The computer uses binary numbers (Binary Numbers) consisting of bits (0 and 1) in its native language to process the data, and thus it understands the entered data by going through some operations.
  • In order for the computer to understand the code, code is first written using a programming language. Then, it is compiled and interpreted in the software development environment, made understandable and executed by the computer.
  • As a result, computers express themselves through the numbers 0 and 1. Everything on the computer consists of 1s and 0s.

--

--

Erdeniz Tunç
Erdeniz Tunç

Written by Erdeniz Tunç

I share my notes. Especially in Product Management

No responses yet