Arc is a
programming language
A programming language is a system of notation for writing computer programs. Most programming languages are text-based formal languages, but they may also be graphical. They are a kind of computer language.
The description of a programming l ...
, a
dialect
The term dialect (from Latin , , from the Ancient Greek word , 'discourse', from , 'through' and , 'I speak') can refer to either of two distinctly different types of linguistic phenomena:
One usage refers to a variety of a language that ...
of the language
Lisp
A lisp is a speech impairment in which a person misarticulates sibilants (, , , , , , , ). These misarticulations often result in unclear speech.
Types
* A frontal lisp occurs when the tongue is placed anterior to the target. Interdental lispi ...
, developed by
Paul Graham and
Robert Morris. It is
free and open-source software
Free and open-source software (FOSS) is a term used to refer to groups of software consisting of both free software and open-source software where anyone is freely licensed to use, copy, study, and change the software in any way, and the source ...
released under the
Artistic License
Artistic license (alongside more contextually-specific derivative terms such as poetic license, historical license, dramatic license, and narrative license) refers to deviation from fact or form for artistic purposes. It can include the alterat ...
2.0.
History
In 2001, Paul Graham announced that he was working on a new
dialect
The term dialect (from Latin , , from the Ancient Greek word , 'discourse', from , 'through' and , 'I speak') can refer to either of two distinctly different types of linguistic phenomena:
One usage refers to a variety of a language that ...
of Lisp named ''Arc''. Over the years since, he has written several essays describing features or goals of the language, and some internal projects at Graham's
startup
A startup or start-up is a company or project undertaken by an entrepreneur to seek, develop, and validate a scalable business model. While entrepreneurship refers to all new businesses, including self-employment and businesses that never intend t ...
business incubator
Business incubator is an organization that helps startup companies and individual entrepreneurs to develop their businesses by providing a fullscale range of services starting with management training and office space and ending with venture c ...
named
Y Combinator
Y Combinator (YC) is an American technology startup accelerator launched in March 2005. It has been used to launch more than 3,000 companies, including Airbnb, Coinbase, Cruise, DoorDash, Dropbox, Instacart, Quora, PagerDuty, Reddit, Str ...
have been written in Arc, most notably the
Hacker News web forum and news aggregator program. Arc is written in
Racket
Racket may refer to:
* Racket (crime), a systematised element of organized crime
** Protection racket, a scheme whereby a group provides protection to businesses or other groups through violence outside the sanction of the law
* Racket (sports equ ...
.
Motives
In the essay ''Being Popular'' Graham describes a few of his goals for the language. While many of the goals are very general ("Arc should be hackable", "there should be good
libraries
A library is a collection of materials, books or media that are accessible for use and not just for display purposes. A library provides physical (hard copies) or digital access (soft copies) materials, and may be a physical location or a vir ...
"), he did give some specifics. For example, he believes it important for a language to be terse:
He also stated that it is better for a language to only implement a small number of ''axioms'', even when that means the language may not have features that large organizations want, such as
object-orientation (OO). Further, Graham thinks that OO is not useful as its methods and
patterns
A pattern is a regularity in the world, in human-made design, or in abstract ideas. As such, the elements of a pattern repeat in a predictable manner. A geometric pattern is a kind of pattern formed of geometric shapes and typically repeated li ...
are just "good design", and he views the language features used to implement OO as partly mistaken. At Arc's introduction in 2008, Graham stated one of its benefits was its brevity.
A controversy among Lisp programmers is whether, and how much, the
s-expression
In computer programming, an S-expression (or symbolic expression, abbreviated as sexpr or sexp) is an expression in a like-named notation for nested list (tree-structured) data. S-expressions were invented for and popularized by the programming la ...
s of the language should be complemented by other forms of
syntax. Graham thinks that added syntax should be used in situations where pure s-expressions would be overly verbose, saying, "I don't think we should be religiously opposed to introducing syntax into Lisp." Graham also thinks that efficiency problems should be solved by giving the programmer a good
profiler.
Reception
When released in 2008, Arc generated mixed reactions, with some calling it simply an extension to Lisp or
Scheme and not a programming language in its own right. Others applauded Arc for stripping Lisp down to bare essentials. Shortly after its release, Arc was ported to
JavaScript
JavaScript (), often abbreviated as JS, is a programming language that is one of the core technologies of the World Wide Web, alongside HTML and CSS. As of 2022, 98% of Website, websites use JavaScript on the Client (computing), client side ...
, and was being supported by ''Schemescript'', an
integrated development environment
An integrated development environment (IDE) is a software application that provides comprehensive facilities to computer programmers for software development. An IDE normally consists of at least a source code editor, build automation tools a ...
(IDE) based on
Eclipse
An eclipse is an astronomical event that occurs when an astronomical object or spacecraft is temporarily obscured, by passing into the shadow of another body or by having another body pass between it and the viewer. This alignment of three ce ...
.
Examples
Hello world
''Hello'' is a salutation or greeting in the English language. It is first attested in writing from 1826. Early uses
''Hello'', with that spelling, was used in publications in the U.S. as early as the 18 October 1826 edition of the '' Norwich ...
in Arc :
(prn "Hello, World")
To illustrate Arc's terseness, Graham uses a brief program. It produces a form with one field at the url "/said". When the form is submitted, it leads to a page with a link that says "click here", which then leads to a page with the value of the original input field.
(defop said req
(aform nlink "click here" (pr "you said: " (arg _ "foo")) (input "foo")
(submit)))
Versions
Official version
The first publicly released version of Arc was made available on 29 January 2008, implemented on
Racket
Racket may refer to:
* Racket (crime), a systematised element of organized crime
** Protection racket, a scheme whereby a group provides protection to businesses or other groups through violence outside the sanction of the law
* Racket (sports equ ...
(named PLT-Scheme then). The release comes in the form of a
.tar
In computing, tar is a computer software utility for collecting many files into one archive file, often referred to as a tarball, for distribution or backup purposes. The name is derived from "tape archive", as it was originally developed ...
archive, containing the Racket
source code
In computing, source code, or simply code, is any collection of code, with or without comment (computer programming), comments, written using a human-readable programming language, usually as plain text. The source code of a Computer program, p ...
for Arc. A tutorial and a discussion forum are also available. The forum uses the same program that
Hacker News does, and is written in Arc.
Unofficial versions
Due to lack of updates in the official Arc branch, some members of the Arc
community
A community is a social unit (a group of living things) with commonality such as place, norms, religion, values, customs, or identity. Communities may share a sense of place situated in a given geographical area (e.g. a country, villag ...
started their own repositories with unofficial modifications, extensions, and libraries. One version, ''Anarki'', permitted anyone to submit changes to the project and has a community managed wiki.
''Rainbow'' is an implementation of Arc in
Java
Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
.
''Arcadia''
is an implementation of Arc in
C.
References
External links
*
Tutorial*
{{Lisp programming language
Dynamically typed programming languages
Functional languages
Lisp programming language family
Cross-platform free software