Algorithm: Difference between revisions

Content deleted Content added
Isis~enwiki (talk | contribs)
m fix typo
Isis~enwiki (talk | contribs)
m fix typo
Line 7:
** b. If the 2nd one is alphabetically ahead of the 1st one, swap the two of them and then go to step 2.
* Step 2. Pretend the 2nd and 3rd names on the list are the 1st and 2nd ones, and repeat step 1.
This is a rule either a human being or a computer can use to alphabetize a list -- it's called a "[[Bubble sort|bubble sort]]", because the entries that belong at the top of the list eventually float up to the top, but it's not a very efficient way to get the job done. So it's not a particularly good algorithm to use, but it's a fair example of what an algorithm is.
 
The word ''algorithm'' is a corruption of the word ''algorism'' which came from the name of [[al-Khwarizmi|Abu Ja'far Mohammed ibn Musa al-Khwarizmi]] (ca. [[780]] - ca. [[845]]). He was the author of the book "''Kitab al-jabr w'al-muqabala''" (''Rules of Restoration and Reduction'') which introduced [[Algebra|algebra]] to people in [[the West]]. The word ''[[algebra]]'' itself originates from ''al-Jabr'' from the book title. The word "algorism" originally referred only to the rules of performing [[arithmetic]] using [[Arabic numerals]] but evolved into "algorithm" by the [[18th century]]. The word has now evolved to include all definite procedures for solving problems and is sometimes used to describe procedures for humans doing physical tasks -- [[cooking]], for instance. The remainder of this article relates to the definition of algorithm as advanced in this article's first sentence.