# Interactive programming

> Mediated Wiki article. Canonical URL: https://mediated.wiki/source/Interactive_programming
> Markdown URL: https://mediated.wiki/source/Interactive_programming.md
> Source: https://en.wikipedia.org/wiki/Interactive_programming
> Source revision: 1347357682
> License: Creative Commons Attribution-ShareAlike 4.0 International (https://creativecommons.org/licenses/by-sa/4.0/)

{{Short description|Procedure of writing program parts while active}}
{{Redirect|Live programming|live broadcasting television and/or radio programming|Broadcast programming}}
{{Distinguish|Live coding}}
{{needs more sources|date=September 2021}}

thumb|200px|right|Interactive programming vs. standard programming
'''Interactive programming''' is the procedure of writing parts of a program while it is already active.<ref>{{cite book |last1=Goldberg |first1=Adele |author1-link=Adele Goldberg (computer scientist) |editor1-last=Harrison |editor1-first=Michael A. |editor1-link=Michael A. Harrison |title=Smalltalk-80: The Interactive Programming Environment |date=1984 |publisher=[Addison-Wesley](/source/Addison-Wesley) |location=[Xerox Palo Alto Research Center](/source/Xerox_Palo_Alto_Research_Center) |isbn=0-201-11372-4 |page=99 (111 in PDF) |url=https://hal.science/hal-05183024v1 |archive-url=https://web.archive.org/web/20251125162812/https://hal.science/hal-05183024v1 |archive-date=2025-11-25 |language=en |quote=§ 5.4, Overview of the Programming Process. Programming in the [Smalltalk-80](/source/Smalltalk-80) system involves [specifying] class descriptions, creating instances of classes, and sequencing messages to the instances. In the course of using the system, you interact with various views that give you access to the classes in the system, messages, methods [...], expressions [...], and intermediate execution states. The programming environment supports describing classes in an incremental fashion. The "class editor" is presented in the form of a {{em|browser}}, which is a way to present a hierarchical index to classes and to messages. |url-status=live |via=[HAL open science](/source/HAL_open_science)}}</ref> This focuses on the program text as the main [interface](/source/User_interface) for a running process, rather than an [interactive application](/source/Interactive_computing), where the program is designed in [development cycle](/source/development_cycle)s and used thereafter (usually by a so-called "user", in distinction to the "developer"). Consequently, here, {{em|the activity of writing a program becomes part of the program itself}}.{{citation needed|date=November 2025}}

It thus forms a specific instance of [interactive computation](/source/interactive_computation) as an extreme opposite to [batch processing](/source/batch_processing), where neither writing the program nor its use happens in an interactive way. The principle of ''rapid feedback'' in [extreme programming](/source/extreme_programming) is radicalized and becomes more explicit.

It is also known as on-the-fly-programming, just in time programming, or conversational programming.{{citation needed|date=November 2025}}

== Application fields ==
{{uncited section|date=November 2025}}
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](/source/Smalltalk) is famous for. Generally, [dynamic programming language](/source/dynamic_programming_language)s provide the environment for such an interaction, so that typically [prototyping](/source/Software_prototyping) and [iterative and incremental development](/source/iterative_and_incremental_development) 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,{{when?|date=November 2025}} researchers have been using this method to develop [sonification](/source/sonification) algorithms.

Using dynamic programming languages for sound and graphics, interactive programming is also used as an improvisational performance style [live coding](/source/live_coding), mainly in algorithmic music and video.

In contemporary digital contexts, interactive programming techniques have also gained relevance in areas such as localized software development and intelligent information systems, where adaptability and real-time interaction support region-specific applications and enhance the structuring of machine-readable knowledge. This has contributed to their growing role in environments with growing relevance in information retrieval and automated answer generation.<ref>{{Cite web |title=Generative Engine Optimization |url=https://especialistaemseo.ia.br/}}</ref>

== Example code ==
{{External links|section|date=November 2025}}
*Live coding of 3D graphics in [ActionScript](/source/ActionScript) using COLT<ref>https://www.youtube.com/watch?v=V4yoe1K080</ref>{{Dead link|date=November 2025 |fix-attempted=yes |url=https://www.youtube.com/watch?v=V4yoe1K080}}
*An example of some code in the dynamic programming language [SuperCollider](/source/SuperCollider) is available [http://swiki.hfbk-hamburg.de:8888/MusicTechnology/739 here].
*Another example, written in [ChucK](/source/ChucK) is available [http://wiki.cs.princeton.edu/index.php/FractalMelody.ck here]
*Live coding of graphics with [http://www.pawfal.org/Software/fluxus/ fluxus]: [https://web.archive.org/web/20060105163947/http://www.pawfal.org/Software/fluxus/images/ribbon.png a screenshot]
* [Impromptu (programming environment)](/source/Impromptu_(programming_environment))
*An example of livecoding in English with [https://vimeo.com/50530082 Quoth]
*[https://elm-lang.org/news/interactive-programming Hot-swapping] in the [functional reactive programming](/source/functional_reactive_programming) language [Elm](/source/Elm_(programming_language))

==See also==
* [Live coding](/source/Live_coding)
* [Rapid application development](/source/Rapid_application_development)
* [Read–eval–print loop](/source/Read%E2%80%93eval%E2%80%93print_loop)

==References==
{{reflist}}

{{Programming paradigms navbox}}
Category:Programming paradigms

---
Adapted from the Wikipedia article [Interactive programming](https://en.wikipedia.org/wiki/Interactive_programming) by Wikipedia contributors ([contributor history](https://en.wikipedia.org/wiki/Interactive_programming?action=history)). Available under [Creative Commons Attribution-ShareAlike 4.0 International](https://creativecommons.org/licenses/by-sa/4.0/). Changes may have been made.
