ICON

Icon is associated with a high level computer programming language rising from the Snobol4 languages, CLU and C (K&R). It is an imperative and procedural language, whose syntax resembles the languages C and Pascal (language).

History

Icon was creates in 1980 by Griswold (University of Arizona). The evolution of Icon continues, its version is currently the 9. Its successor is Unicon creates at the University of Nevada, which integrates in more one layer object, a more complete interface with Unix and an interface with SQL.

Examples of code

Let us start with traditional the Hello world :

# Helloworld procedure hand () Write (" Hello World! ") end

Here a sample program Icon which reads in entry a file and posts on the standard exit the file with the numbered lines:

# This is a comment procedure hand (args) file: = &input file: = open (args) | stop (" Error of opening of fichier") numerote_ligne (file) end procedure numerote_ligne (file) count: = 0 while line: = read (file) C writes (account +: = 1, " " , line, " \ n") end

Concepts

ICON is a high-level language, which means that it makes it possible to the programmer to use concepts rather far away from real operation of a machine. So he proposes various very advanced mechanisms like the generators or the evaluation directed by the goal.

The generating make it possible, starting from an expression, to provide a succession of values. For example: every I: = (1 to 3) | (3 to 1 by -1) C… will allow us to vary I from 1 to 3 then from 3 to 1. Or yew (X | there) = (3 | 5) then… allows to test if one of the variables X or there with value 3 or 5

The mechanism of the evaluation directed by the goal makes it possible to launch a series of repetitive operations, without worrying about the case of stop. For example if we would wish to post all the values of a table , we would make: every Write (! )

ICON allows certain constructions, often more known functional languages, but nevertheless strong practices: Write (box I off { 0: " parfait" 1|- 1: " not loin" default: " far… " })

Here another example to show the power of the various existing operators in the case of the mixture of a table: every 1 to *tab C ? : =: ?

External bonds

  • Official site
  • small outline of Icon

Random links:Salma Hayek | Claudette Colbert | Eppa Rixey | Attributive clause of competence | Kuhliidae | Centre_faisant_le_coin_de_Tysons