Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Python (programming language)
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{Short description|General-purpose programming language}} {{Use dmy dates|date=November 2021}} {{Use American English|date=December 2024}} {{Infobox programming language | logo = Python-logo-notext.svg | logo size = 150px | paradigm = [[Multi-paradigm]]: [[object-oriented]],<ref>{{Cite web|title=General Python FAQ β Python 3 documentation|url=https://docs.python.org/3/faq/general.html#what-is-python|access-date=2024-07-07|website=docs.python.org}}</ref> [[Procedural programming|procedural]] ([[Imperative programming|imperative]]), [[Functional programming|functional]], [[Structured programming|structured]], [[Reflective programming|reflective]] | released = {{start date and age|1991|02|20|df=y}}<ref name="alt-sources-history">{{cite web |url=https://www.tuhs.org/Usenet/alt.sources/1991-February/001749.html |title=Python 0.9.1 part 01/21 |publisher=alt.sources archives |access-date=2021-08-11 |archive-date=11 August 2021 |archive-url=https://web.archive.org/web/20210811171015/https://www.tuhs.org/Usenet/alt.sources/1991-February/001749.html |url-status=live}}</ref> | designer = [[Guido van Rossum]] | developer = [[Python Software Foundation]] | latest release version = {{wikidata|property|P548=Q2804309|P348}} | latest release date = {{start date and age|{{wikidata|qualifier|single|P548=Q2804309|P348|P577}}}} | latest preview version = {{wikidata|property|edit|reference|P548=Q51930650|P348}} | latest preview date = {{start date and age|{{wikidata|qualifier|single|P548=Q51930650|P348|P577}}}} | typing = [[Duck typing|duck]], [[Dynamic typing|dynamic]], [[Strong and weak typing|strong]];<ref>{{Cite web|title=Why is Python a dynamic language and also a strongly typed language |url=https://wiki.python.org/moin/Why%20is%20Python%20a%20dynamic%20language%20and%20also%20a%20strongly%20typed%20language|access-date=2021-01-27|website=Python Wiki |archive-date=14 March 2021|archive-url=https://web.archive.org/web/20210314173706/https://wiki.python.org/moin/Why%20is%20Python%20a%20dynamic%20language%20and%20also%20a%20strongly%20typed%20language|url-status=live}}</ref> [[Optional typing|optional type annotations]] (since 3.5, but those hints are ignored, except with unofficial tools)<ref name="type_hint-PEP">{{cite web|url=https://www.python.org/dev/peps/pep-0483/|title=PEP 483 β The Theory of Type Hints|website=Python.org|access-date=14 June 2018|archive-date=14 June 2020|archive-url=https://web.archive.org/web/20200614153558/https://www.python.org/dev/peps/pep-0483/|url-status=live}}</ref> | implementations = [[CPython]], [[PyPy]], [[Stackless Python]], [[MicroPython]], [[CircuitPython]], [[IronPython]], [[Jython]] | operating system = {{plainlist| *'''Tier 1''': 64-bit [[Linux]], [[macOS]]; 64- and 32-bit [[Windows]] 10+<ref>{{Cite web |title=PEP 11 β CPython platform support {{!}} peps.python.org |url=https://peps.python.org/pep-0011/ |access-date=2024-04-22 |website=Python Enhancement Proposals (PEPs) |language=en}}</ref><!-- Not "Windows for IoT and embedded systems"; NOT UNIX, it's not listed, nor any Unix-like, maybe implied Possibly Windows 8.1 is also supported on at least Python 3.9? Might also work on latest, seems too minor to mention, for any Python version. Windows 7 and 8 are prevented to work on Python 3.9, though it might not rule out 8.1, also some info like this might be a bit wrong: "Windows 8 and newer for Python 3.9 FreeBSD 10 and newer macOS Snow Leopard (macOS 10.6, 2008) and newer" --> *'''Tier 2''': E.g. 32-bit [[WebAssembly]] (WASI) <!-- (WASI SDK, Wasmtime) meaning wasm32-unknown-wasi; wasm32-unknown-emscripten is unsupported since 3.13. aarch64-pc-windows-msvc and powerpc64le-unknown-linux-gnu --> *'''Tier 3''': 64-bit [[Android (operating system)|Android]]<!-- too much trivia to mention "5.0+", even if true, it seemingly is, and corresponding API levels, but thouse are ancient, possibly even only way more recent is officially supported? -->,<ref>{{Cite web |title=PEP 738 β Adding Android as a supported platform {{!}} peps.python.org |url=https://peps.python.org/pep-0738/ |access-date=2024-05-19 |website=Python Enhancement Proposals (PEPs) |language=en}}</ref> [[iOS]], [[FreeBSD]], and (32-bit) [[Raspberry Pi OS]]<br />Unofficial (or has been known to work): Other [[Unix-like]]/[[BSD]] variants) and a few other platforms<!-- Used to support many more, only few support latest 3.9+ --><ref>{{Cite web |title=Download Python for Other Platforms |url=https://www.python.org/download/other/ |access-date=2023-08-18 |website=Python.org |language=en |archive-date=27 November 2020 |archive-url=https://web.archive.org/web/20201127015815/https://www.python.org/download/other/ |url-status=live}}</ref><ref>{{Cite web |title=test β Regression tests package for Python β Python 3.7.13 documentation |url=https://docs.python.org/3.7/library/test.html?highlight=android#test.support.is_android |access-date=2022-05-17 |website=docs.python.org |archive-date=17 May 2022 |archive-url=https://web.archive.org/web/20220517151240/https://docs.python.org/3.7/library/test.html?highlight=android#test.support.is_android |url-status=live}}</ref><ref>{{Cite web |title=platform β Access to underlying platform's identifying data β Python 3.10.4 documentation |url=https://docs.python.org/3/library/platform.html?highlight=android |access-date=2022-05-17 |website=docs.python.org |archive-date=17 May 2022 |archive-url=https://web.archive.org/web/20220517150826/https://docs.python.org/3/library/platform.html?highlight=android |url-status=live}}</ref>}} <!-- https://mail.python.org/archives/list/python-committers@python.org/thread/K757345KX6W5ZLTWYBUXOXQTJJTL7GW5/ * Alpine / musl is not supported, because our test suite is failing due to bugs and missing features in musl libc. * NetBSD and OpenBSD are in a similar state as Alpine: no stable buildbot and AFAIK tests are failing * [outdated] * Cygwin and MinGW are officially unsupported, see bpo-45537 and bpo-45538 .. The policy Brett is proposing just makes that explicit and gives us something to point to when someone comes up with a patch to support PDP-11 or when someone's patch for Android breaks Windows. I don't think we'll wind up with tier support police; if a core dev wants to take responsibility for a patch for a platform that is not tier 3 or above they can still do that, but if it breaks things for a supported platform it will be reverted. .. E.g. Android support was even funded by the PSF recently. [outdated] Also note that the stdlib does in fact support other Python implementations reusing (parts of) it, e.g. Jython, PyPy and IronPython. Again, without core devs backing these. --> | license = [[Python Software Foundation License]] | file ext = .py, .pyw, .pyz,<!-- Too much trivia?: (since 3.5), since 3.8 latest supported and Python 3.5.10 Sept. 5, 2020--><ref>{{cite web |url=https://www.python.org/dev/peps/pep-0441/ |last=Holth |first=Moore |date=30 March 2014 |access-date=12 November 2015 |title=PEP 0441 β Improving Python ZIP Application Support |archive-date=26 December 2018 |archive-url=https://web.archive.org/web/20181226141117/https://www.python.org/dev/peps/pep-0441/%20 |url-status=live}}</ref><br /> .pyi, .pyc, .pyd<!-- too much trivia: .pyo (before 3.5)<ref>File extension .pyo was removed in Python 3.5. See [https://www.python.org/dev/peps/pep-0488/ PEP 0488] {{Webarchive|url=https://web.archive.org/web/20200601133202/https://www.python.org/dev/peps/pep-0488/ |date=1 June 2020}}</ref> --> | website = {{URL|https://www.python.org/|python.org}} | dialects = [[Cython]], [[RPython]], [[Bazel (software)|Starlark]]<ref>{{cite web|title=Starlark Language|url=https://docs.bazel.build/versions/master/skylark/language.html|access-date=25 May 2019|archive-date=15 June 2020|archive-url=https://web.archive.org/web/20200615140534/https://docs.bazel.build/versions/master/skylark/language.html|url-status=live}}</ref> | influenced by = [[ABC (programming language)|ABC]],<ref name="faq-created"/> [[Ada (programming language)|Ada]],<ref>{{cite web |url=https://archive.adaic.com/standards/83lrm/html/lrm-11-03.html#11.3 |title=Ada 83 Reference Manual (raise statement) |access-date=7 January 2020 |archive-date=22 October 2019 |archive-url=https://web.archive.org/web/20191022155758/http://archive.adaic.com/standards/83lrm/html/lrm-11-03.html#11.3 |url-status=live}}</ref> [[ALGOL 68]],<ref name="98-interview"/> <br />[[APL (programming language)|APL]],<ref name="python.org">{{cite web|url=https://docs.python.org/3/library/itertools.html|title=itertools β Functions creating iterators for efficient looping β Python 3.7.1 documentation|website=docs.python.org|access-date=22 November 2016|archive-date=14 June 2020|archive-url=https://web.archive.org/web/20200614153629/https://docs.python.org/3/library/itertools.html |quote=This module implements a number of iterator building blocks inspired by constructs from APL, Haskell, and SML. |url-status=live}}</ref> [[C (programming language)|C]],<ref name="AutoNT-1"/> [[C++]],<ref name="classmix"/> [[CLU (programming language)|CLU]],<ref name="effbot-call-by-object"/> [[Dylan (programming language)|Dylan]],<ref name="AutoNT-2"/> <br />[[Haskell]],<ref name="AutoNT-3"/><ref name="python.org"/> [[Icon (programming language)|Icon]],<ref name="AutoNT-4"/> [[Lisp (programming language)|Lisp]],<ref name="AutoNT-6"/> {{nowrap|<br />[[Modula-3]]}},{{r|98-interview}}<ref name="classmix"/> [[Perl]],<ref>{{cite web |title=re β Regular expression operations β Python 3.10.6 documentation |url=https://docs.python.org/3/library/re.html |website=docs.python.org |access-date=2022-09-06 |quote=This module provides regular expression matching operations similar to those found in Perl. |archive-date=18 July 2018 |archive-url=https://web.archive.org/web/20180718132241/https://docs.python.org/3/library/re.html |url-status=live}}</ref> [[Standard ML]]<ref name="python.org"/> | influenced = [[Apache Groovy]], [[Boo (programming language)|Boo]], [[Cobra (programming language)|Cobra]], [[CoffeeScript]],<ref>{{Cite web|url=https://coffeescript.org/|title=CoffeeScript|website=coffeescript.org|access-date=3 July 2018|archive-date=12 June 2020|archive-url=https://web.archive.org/web/20200612100004/http://coffeescript.org/|url-status=live}}</ref> [[D (programming language)|D]], [[F Sharp (programming language)|F#]], [[GDScript]], [[Go (programming language)|Go]], [[JavaScript]],<ref>{{cite web |title=Perl and Python influences in JavaScript |date=24 February 2013 |website=www.2ality.com |url=https://www.2ality.com/2013/02/javascript-influences.html |access-date=15 May 2015 |archive-date=26 December 2018 |archive-url=https://web.archive.org/web/20181226141121/http://2ality.com/2013/02/javascript-influences.html%0A |url-status=live }}</ref><ref>{{cite web |title=Chapter 3: The Nature of JavaScript; Influences |last=Rauschmayer |first=Axel |website=O'Reilly, Speaking JavaScript |url=http://speakingjs.com/es5/ch03.html |access-date=15 May 2015 |archive-date=26 December 2018 |archive-url=https://web.archive.org/web/20181226141123/http://speakingjs.com/es5/ch03.html%0A |url-status=live }}</ref> [[Julia (programming language)|Julia]],<ref name=Julia/> [[Mojo (programming language)|Mojo]],<ref name="Mojo">{{Cite web |last=Krill |first=Paul |date=2023-05-04 |title=Mojo language marries Python and MLIR for AI development |url=https://www.infoworld.com/article/3695588/mojo-language-marries-python-and-mlir-for-ai-development.html |access-date=2023-05-05 |website=InfoWorld |language=en |archive-date=5 May 2023 |archive-url=https://web.archive.org/web/20230505064554/https://www.infoworld.com/article/3695588/mojo-language-marries-python-and-mlir-for-ai-development.html |url-status=live}}</ref> [[Nim (programming language)|Nim]], [[Ring (programming language)|Ring]],<ref name="The Ring programming language and other languages">{{cite web |url=https://ring-lang.sourceforge.net/doc1.6/introduction.html#ring-and-other-languages |title=Ring and other languages |author=Ring Team |date=4 December 2017 |work=ring-lang.net |publisher=[[ring-lang]] |access-date=4 December 2017 |archive-date=25 December 2018 |archive-url=https://web.archive.org/web/20181225175312/http://ring-lang.sourceforge.net/doc1.6/introduction.html#ring-and-other-languages |url-status=live}}</ref> [[Ruby (programming language)|Ruby]],<ref name="bini"/> [[Swift (programming language)|Swift]],<ref name="lattner2014">{{Cite web |url=http://nondot.org/sabre/ |title=Chris Lattner's Homepage |last=Lattner |first=Chris |date=3 June 2014 |access-date=3 June 2014 |publisher=Chris Lattner |quote=The Swift language is the product of tireless effort from a team of language experts, documentation gurus, compiler optimization ninjas, and an incredibly important internal dogfooding group who provided feedback to help refine and battle-test ideas. Of course, it also greatly benefited from the experiences hard-won by many other languages in the field, drawing ideas from Objective-C, Rust, Haskell, Ruby, Python, C#, CLU, and far too many others to list. |archive-date=25 December 2018 |archive-url=https://web.archive.org/web/20181225175312/http://nondot.org/sabre/ |url-status=live}}</ref> [[V (programming language)|V]]<ref name="vpeople">{{Cite web |title=V documentation (Introduction) |url=https://github.com/vlang/v/blob/master/doc/docs.md#introduction |access-date=2024-12-24|website=GitHub |language=en}}</ref> <!-- Do not put in as there's also a pure Java implementation (Jython): | programming language = [[C (programming language)|C]] --> | wikibooks = Python Programming }} '''Python''' is a [[high-level programming language|high-level]], [[general-purpose programming language]]. Its design philosophy emphasizes [[code readability]] with the use of [[significant indentation]].<ref name="AutoNT-7"/> Python is [[type system#DYNAMIC|dynamically type-checked]] and [[garbage collection (computer science)|garbage-collected]]. It supports multiple [[programming paradigm]]s, including [[structured programming|structured]] (particularly [[procedural programming|procedural]]), [[object-oriented]] and [[functional programming]]. It is often described as a "batteries included" language due to its comprehensive [[standard library]].<ref name="About"/><ref>{{Cite web|title=PEP 206 β Python Advanced Library|url=https://www.python.org/dev/peps/pep-0206/|url-status=live|archive-url=https://web.archive.org/web/20210505003659/https://www.python.org/dev/peps/pep-0206/|archive-date=5 May 2021|access-date=11 October 2021|website=Python.org}}</ref> [[Guido van Rossum]] began working on Python in the late 1980s as a successor to the [[ABC (programming language)|ABC]] programming language, and he first released it in 1991 as Python 0.9.0.<ref>{{Cite web|last=Rossum|first=Guido Van|date=2009-01-20|title=The History of Python: A Brief Timeline of Python|url=https://python-history.blogspot.com/2009/01/brief-timeline-of-python.html|access-date=2021-03-05|website=The History of Python|archive-date=5 June 2020|archive-url=https://web.archive.org/web/20200605032200/https://python-history.blogspot.com/2009/01/brief-timeline-of-python.html|url-status=live}}</ref> Python 2.0 was released in 2000. Python 3.0, released in 2008, was a major revision not completely [[backward-compatible]] with earlier versions. Python 2.7.18, released in 2020, was the last release of Python 2.<ref>{{Cite web|url=https://pythoninsider.blogspot.com/2020/04/python-2718-last-release-of-python-2.html|title= Python 2.7.18, the last release of Python 2|last=Peterson|first=Benjamin|date=20 April 2020|website=Python Insider|access-date=27 April 2020|archive-date=26 April 2020|archive-url=https://web.archive.org/web/20200426204118/https://pythoninsider.blogspot.com/2020/04/python-2718-last-release-of-python-2.html|url-status=live}}</ref> Python consistently ranks as one of the most popular programming languages, and it has gained widespread use in the [[machine learning]] community.<ref>{{Cite web |title=Stack Overflow Developer Survey 2022 |url=https://survey.stackoverflow.co/2022/ |access-date=2022-08-12 |website=Stack Overflow |language=en |archive-date=27 June 2022 |archive-url=https://web.archive.org/web/20220627175307/https://survey.stackoverflow.co/2022/ |url-status=live}}</ref><ref>{{Cite web|title=The State of Developer Ecosystem in 2020 Infographic|url=https://www.jetbrains.com/lp/devecosystem-2020/|access-date=2021-03-05|website=JetBrains: Developer Tools for Professionals and Teams|language=en|archive-date=1 March 2021|archive-url=https://web.archive.org/web/20210301062411/https://www.jetbrains.com/lp/devecosystem-2020/|url-status=live}}</ref><ref name="tiobecurrent">{{cite web |title=TIOBE Index |publisher=TIOBE |url=https://www.tiobe.com/tiobe-index/ |access-date=3 January 2023 |quote=The TIOBE Programming Community index is an indicator of the popularity of programming languages |archive-date=25 February 2018 |archive-url=https://web.archive.org/web/20180225101948/https://www.tiobe.com/tiobe-index/ |url-status=live}} Updated as required.</ref><ref>{{Cite web|title=PYPL PopularitY of Programming Language index|url=https://pypl.github.io/PYPL.html|access-date=2021-03-26|website=pypl.github.io|language=en|archive-date=14 March 2017|archive-url=https://web.archive.org/web/20170314232030/https://pypl.github.io/PYPL.html|url-status=live}}</ref>
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)