Interactive programming is the procedure of writing parts of a program while it is already active. This focuses on the program text as the main
interface for a running process, rather than an
interactive application, where the program is designed in
development cycles and used thereafter (usually by a so-called "user", in distinction to the "developer"). Consequently, here, ''the activity of writing a program becomes part of the program itself.''
It thus forms a specific instance of
interactive computation
In computer science, interactive computation is a mathematical model for computation that involves input/output communication with the external world ''during'' computation.
Uses
Among the currently studied mathematical models of computation th ...
as an extreme opposite to
batch processing
Computerized batch processing is a method of running software programs called jobs in batches automatically. While users are required to submit the jobs, no other interaction by the user is required to process the batch. Batches may automatically ...
, where neither writing the program nor its use happens in an interactive way. The principle of ''rapid feedback'' in
extreme programming
Extreme programming (XP) is a software development methodology intended to improve software quality and responsiveness to changing customer requirements. As a type of agile software development,"Human Centred Technology Workshop 2006 ", 2006, ...
is radicalized and becomes more explicit.
Synonyms: on-the-fly-programming, just in time programming, conversational programming
Application fields
Interactive programming techniques are especially useful in cases where no clear specification of the problem that is to be solved can be given in advance. In such situations (which are not unusual in research), the formal language provides the necessary environment for the development of an appropriate question or problem formulation.
Interactive programming has also been used in applications that need to be rewritten without stopping them, a feature which the computer language
Smalltalk
Smalltalk is a purely object oriented programming language (OOP) that was originally created in the 1970s for educational use, specifically for constructionist learning, but later found use in business. It was created at Xerox PARC by Learni ...
is famous for. Generally,
dynamic programming language
A dynamic programming language is a type of programming language that allows various operations to be determined and executed at runtime. This is different from the compilation phase. Key decisions about variables, method calls, or data types are ...
s provide the environment for such an interaction, so that typically
prototyping
A prototype is an early sample, model, or release of a product built to test a concept or process. It is a term used in a variety of contexts, including semantics, design, electronics, and software programming. A prototype is generally used to ...
and
iterative and incremental development
Iterative and incremental development is any combination of both iterative design (or iterative method) and incremental build model for New product development, development.
Usage of the term began in software development, with a long-standing com ...
is done while other parts of the program are running.
As this feature is an apparent need in sound design and algorithmic composition, it has evolved significantly there. More recently, researchers have been using this method to develop
sonification algorithms.
Using dynamic programming languages for sound and graphics, interactive programming is also used as an improvisational performance style
live coding
Live coding, sometimes referred to as on-the-fly programming,Wang G. & Cook P. (2004"On-the-fly Programming: Using Code as an Expressive Musical Instrument" In ''Proceedings of the 2004 International Conference on New Interfaces for Musical Expr ...
, mainly in algorithmic music and video.
Example code
*Live coding of 3D graphics in
ActionScript
ActionScript is an object-oriented programming language originally developed by Macromedia Inc. (later acquired by Adobe). It is influenced by HyperTalk, the scripting language for HyperCard. It is now an implementation of ECMAScript (mean ...
using COLT
*An example of some code in the dynamic programming language
SuperCollider
SuperCollider is an environment and audio programming language released originally in 1996 by James McCartney for real-time audio synthesis and algorithmic composition.J. McCartneySuperCollider: A new real time synthesis language in Proc. Int ...
is availabl
here
*Another example, written in
ChucK
Chuck () is a masculine given name or a nickname for Charles or Charlie. It may refer to:
People
Arts and entertainment
* Chuck Alaimo, American saxophonist, leader of the Chuck Alaimo Quartet
* Chuck Barris (1929–2017), American TV produce ...
is availabl
here*Live coding of graphics wit
fluxusa screenshot*
impromptu
An impromptu (, , loosely meaning "offhand") is a free-form musical composition with the character of an ''ex tempore'' improvisation as if prompted by the spirit of the moment, usually for a solo instrument, such as piano. According to ''Allgeme ...
*An example of livecoding in English wit
QuothHot-swappingin the
functional reactive programming language
Elm
Elms are deciduous and semi-deciduous trees comprising the genus ''Ulmus'' in the family Ulmaceae. They are distributed over most of the Northern Hemisphere, inhabiting the temperate and tropical- montane regions of North America and Eurasia, ...
See also
*
Live coding
Live coding, sometimes referred to as on-the-fly programming,Wang G. & Cook P. (2004"On-the-fly Programming: Using Code as an Expressive Musical Instrument" In ''Proceedings of the 2004 International Conference on New Interfaces for Musical Expr ...
*
Rapid application development
Rapid application development (RAD), also called rapid application building (RAB), is both a general term for adaptive software development approaches, and the name for James Martin's method of rapid development. In general, RAD approaches to ...
*
Read–eval–print loop
A read–eval–print loop (REPL), also termed an interactive toplevel or language shell, is a simple interactive computer programming environment that takes single user inputs, executes them, and returns the result to the user; a program written ...
References
{{reflist
Programming paradigms