MOTOROBIT — EVERYTHING FOR TECHNOLOGY LOVERS, ALL IN ONE PLACE!
MORE THAN 30,000 PRODUCTS – AN EXTENSIVE PRODUCT RANGE
YOUR PARTNER IN ELECTRONIC COMPONENT SUPPLY
EXPAND YOUR CREATIVITY BEYOND LIMITS WITH MOTOROBIT
{{ t.categories }} ({{ live_data.categories.length }})
{{ t.brands }} ({{ live_data.brands.length }})
{{ t.products }} ({{ live_data.products.length }})
{{ t.see_all }}
Menu
If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!
If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!If you cannot find a specific electronic or automation spare part on our website or in the market, please contact us — quantity does not matter!
What is an Algorithm?
Category:Algoritma
Publish Time: 28.07.2023
Reading Time: 3 Minute
What is an Algorithm?

What is an Algorithm?

 
Algorithm is the designed path to perform a specific task or solve a problem. It is the sum of all the steps required to accomplish a task. It is commonly used in computer programming, and all programming languages are based on algorithms. 
 

History of Algorithms

 
The word Algorithm comes from Ebu Abdullah Muhammed Ibn Musa al-Khwarizmi, who made a significant contribution to the history of mathematics by documenting his algorithmic studies in the 9th century. The Latin translation of his book created a great echo in Europe. Europeans, who could not pronounce the author's name, used the word "algorism" to mean "rules for solving arithmetic problems using Arabic numerals." This word gradually evolved into "algorithm."
 
An algorithm consists of start, end, and intermediate steps. The operation to be performed at each step is clearly specified, and the next step is taken based on the obtained result. The functioning of computers is entirely based on algorithms.
Let's take a simple example to explain. Consider the table on the side. When a bulb does not work at home, we first ask ourselves if the plug is plugged in. If it's not plugged in, we plug it in. But if it still doesn't light up, then we check if the bulb is blown. If the bulb is blown, we replace it. However, if it's still not resolved, we replace the lamp. As you can see, we unknowingly use an algorithmic approach in many aspects of our lives, just like computers do.
 

 

 

 

Flowcharts

 
The graphical representation of the steps in an algorithm is called a flowchart. There are specific symbols in a flowchart, each with a different meaning. 
Ellipse: Used at the beginning or end.
Rectangle: Used in general operations.
Parallelogram: Used in data input and output.
Rhombus: Used in comparisons or conditions.
 
Flowchart

Examples of Algorithms

 
Example 1:  Let's create a flowchart and textual algorithm of a program that takes the average of a student's three exam scores and prints its equivalent in the five-point grading system.
 

Textual Algorithm

A1 : Enter the first score.
A2 : Enter the second score.
A3 : Enter the third score.
A4 : Sum the numbers.
A5 : Divide the total result by three.
A6 : If the average is >= 85, grade=5, go to A11.
A7 : If the average is >= 70, grade=4, go to A11.
A8 : If the average is >= 60, grade=3, go to A11.
A9 : If the average is >= 50, grade=2, go to A11.
A10 : If the average is >= 0, grade=1, go to A11.
A11 : Print the grade.
A12 : End.

Flowchart

Share
T-Soft | Premium