Icon is an actively used programming language created in 1977. Icon is a very high-level programming language featuring goal-directed execution and many facilities for managing strings and textual patterns. It is related to SNOBOL and SL5, string processing languages. Icon is not object-oriented, but an object-oriented extension called Idol was developed in 1996 which eventually became Unicon. Read more on Wikipedia...

43Years Old 525Users ?Jobs

Example code from the Hello World Collection:

# Hello world in Icon (http://www.cs.arizona.edu/icon/)

procedure main()
    write("Hello world")

Example code from Wikipedia:

procedure main()
     s := "Mon Dec 8"
     s ? write(Mdate() | "not a valid date")
 # Define a matching function that returns
 # a string that matches a day month dayofmonth
 procedure Mdate()
 # Define some initial values
 static dates
 static days
 initial {
        days := ["Mon","Tue","Wed","Thr","Fri","Sat","Sun"]
        dates := ["Jan","Feb","Mar","Apr","May","Jun",
 every suspend   (retval <-  tab(match(!days)) ||     # Match a day
                             =" " ||                  # Followed by a blank
                             tab(match(!dates)) ||    # Followed by the month
                             =" " ||                  # Followed by a blank
                             matchdigits(2)           # Followed by at least 2 digits
                 ) &
                 (=" " | pos(0) ) &                   # Either a blank or the end of the string
                 retval                               # And finally return the string
 # Matching function that returns a string of n digits
 procedure matchdigits(n)
     suspend (v := tab(many(&digits)) & *v <= n) & v

Last updated August 9th, 2020

Edit Icon on GitHub