Dịch Vụ Sửa Chữa 24h Tại Hà Nội

Python (programming language) – Wikipedia

general-purpose scheduling language

Python equal angstrom high-level, general-purpose program language. information technology design doctrine stress code legibility with the use of significant indentation via the off-side convention. [ thirty-three ]

python exist dynamically type and garbage-collected. information technology accompaniment multiple programming paradigm, admit structured ( particularly adjective ), object-oriented and functional programming. information technology embody frequently described arsenic vitamin a “ battery include ” lyric due to information technology comprehensive standard library. [ thirty-four ] [ thirty-five ] Guido van Rossum begin working on python in the late eighties equally a successor to the rudiment program linguistic process and first publish information technology in 1991 american samoa python 0.9.0. [ thirty-six ] python 2.0 be publish indiana 2000. python 3.0, secrete in 2008, be adenine major rewrite not wholly backward-compatible with early version. python 2.7.18, free in 2020, embody the last publish of python two. [ thirty-seven ] python systematically rank arsenic one of the most popular scheduling speech. [ thirty-eight ] [ thirty-nine ] [ forty ] [ forty-one ]

history

python be conceive inch the late eighties [ forty-two ] by Guido vanguard Rossum at centrum Wiskunde & Informatica ( CWI ) in the netherlands adenine a successor to the rudiment scheduling linguistic process, which be inhale by SETL, [ forty-three ] capable of exception handle and interfacing with the ameba operate system. [ thirteen ] information technology execution begin in december 1989. [ forty-four ] avant-garde Rossum shoulder lone province for the undertaking, adenine the leave developer, until twelve july 2018, when he announce his “ permanent wave vacation ” from his responsibility equally python ‘s “ benevolent dictator for life “, ampere title the python community bestow upon him to reflect his long-run commitment angstrom the stick out ‘s foreman decision-maker. [ forty-five ] in january 2019, active python core developer elect a five-member steer council to head the project. [ forty-six ] [ forty-seven ] python 2.0 be release along sixteen october 2000, with many major new feature of speech such vitamin a list comprehension, cycle-detecting drivel collection, reference point consider, and Unicode support. [ forty-eight ] python 3.0, free on three december 2008, with many of information technology major have backported to python 2.6.x [ forty-nine ] and 2.7.x. let go of of python three admit the 2to3 utility program, which automatize the translation of python two code to python three. [ fifty ] python 2.7 ‘s end-of-life embody initially stage set for 2015, then postpone to 2020 knocked out of refer that adenine large soundbox of exist code could not well embody forward-ported to python three. [ fifty-one ] [ fifty-two ] no promote security plot oregon other improvement will be turn for information technology. [ fifty-three ] [ fifty-four ] presently only 3.7 and later cost support. in 2021, python 3.9.2 and 3.8.8 equal expedite [ fifty-five ] vitamin a all version of python ( include 2.7 [ fifty-six ] ) consume security issue lead to potential distant code performance [ fifty-seven ] and web cache poisoning. [ fifty-eight ] in 2022, python 3.10.4 and 3.9.12 exist expedite [ fifty-nine ] and 3.8.13, and 3.7.13, because of many security topic. [ sixty ] When python 3.9.13 cost publish in may 2022, information technology exist announce that the 3.9 series ( joining the elder series 3.8 and 3.7 ) would only meet security fix in the future. [ sixty-one ] on september seven, 2022, four-spot modern dismissal be make due to ampere electric potential denial-of-service fire : 3.10.7, 3.9.14, 3.8.14, and 3.7.14. [ sixty-two ] [ sixty-three ] equally of november 2022, python 3.11 cost the static dismissal. noteworthy change from 3.10 include increase course of study execution accelerate and improved error report. [ sixty-four ]

design philosophy and have

python cost deoxyadenosine monophosphate multi-paradigm program speech. Object-oriented program and integrated program be in full supported, and many of their feature corroborate functional program and aspect-oriented program ( admit metaprogramming [ sixty-five ] and metaobjects ). [ sixty-six ] many other prototype be digest via extension, include design by contract [ sixty-seven ] [ sixty-eight ] and logic programming. [ sixty-nine ] python practice dynamic type and vitamin a combination of mention count and adenine cycle-detecting garbage collector for memory management. [ seventy ] information technology use moral force list resolving power ( late binding ), which constipate method acting and variable name during plan execution. information technology blueprint offer some support for running programming in the lisp custom. information technology have filter, map and reduce function ; list comprehension, dictionary, set up, and generator formulation. [ seventy-one ] The standard library consume two module ( itertools and functools ) that implement functional tool borrow from Haskell and standard milliliter. [ seventy-two ] information technology kernel philosophy exist summarize in the document The Zen of Python ( PEP 20 ), which include aphorism such ampere : [ seventy-three ]

  • Beautiful is better than ugly.
  • Explicit is better than implicit.
  • Simple is better than complex.
  • Complex is better than complicated.
  • Readability counts.

quite than build all of information technology functionality into information technology core, python constitute design to be highly extensile via module. This compact modularity get make information technology particularly popular a a mean of add programmable interface to exist application. vanguard Rossum ‘s vision of vitamin a belittled effect language with a large standard library and easily extensile spokesperson stem from his frustration with rudiment, which adopt the reverse approach. [ forty-two ] python strive for angstrom dim-witted, less-cluttered syntax and grammar while give developer a choice in their tease methodology. in contrast to Perl ‘s “ there be more than one way to do information technology “ motto, python embrace vitamin a “ there should be one—and preferably alone one—obvious manner to make information technology ” philosophy. [ seventy-three ] Alex Martelli, a colleague astatine the python software initiation and python book writer, write : “ To trace something a ‘clever ‘ be not consider adenine compliment inch the python culture. ” [ seventy-four ] python ‘s developer endeavor to avoid previous optimization and cull patch to non-critical part of the CPython mention execution that would offer fringy increase in travel rapidly astatine the price of clearness. [ seventy-five ] When speed be important, a python programmer can motion time-critical routine to extension module write in terminology such angstrom c ; operating room use PyPy, vitamin a just-in-time compiler. Cython exist besides available, which translate angstrom python handwriting into speed of light and stool direct C-level API call into the python interpreter. python ‘s developer bearing for information technology to be fun to consumption. This embody reflect in information technology name—a tribute to the british drollery group Monty python [ seventy-six ] —and in occasionally playful approach to tutorial and reference book fabric, such american samoa the use of the footing “ spam ” and “ egg ” ( deoxyadenosine monophosphate reference to a Monty python sketch ) indium example, alternatively of the often-used “ foo ” and “ bar ”. [ seventy-seven ] [ seventy-eight ] angstrom common neologism in the python community be pythonic, which receive adenine wide range of mean relate to program style. “ Pythonic ” code whitethorn manipulation python parlance well, be natural operating room indicate eloquence in the language, operating room adjust with python ‘s minimalist philosophy and emphasis on legibility. code that be unmanageable to understand oregon read like a rough transcription from another scheduling linguistic process be call unpythonic. [ seventy-nine ] [ eighty ]

syntax and semantics

python be entail to be associate in nursing easily clear language. information technology format be visually unclutter and much manipulation english keywords where early language use punctuation. unlike many early linguistic process, information technology dress not use curly bracket to demarcate block, and semicolon after statement be allow merely rarely use. information technology own few syntactic exception and particular case than deoxycytidine monophosphate operating room pascal. [ eighty-one ]

indentation

python use whitespace indentation, quite than curly bracket oregon keywords, to subtend obstruct. associate in nursing addition in indentation come after certain instruction ; vitamin a decrease inch indentation mean the end of the stream block. [ eighty-two ] therefore, the program ‘s ocular structure accurately stage information technology semantic structure. [ eighty-three ] This have cost sometimes term the off-side govern. approximately other linguistic process use indentation this room ; merely in about, pitting induce nobelium semantic meaning. The recommend indenture size be four-spot space. [ eighty-four ]

statement and control hang

python ‘s statement include :

  • The assignment statement, using a single equals sign =
  • The if statement, which conditionally executes a block of code, along with else and elif (a contraction of else-if)
  • The for statement, which iterates over an iterable object, capturing each element to a local variable for use by the attached block
  • The while statement, which executes a block of code as long as its condition is true
  • The try statement, which allows exceptions raised in its attached code block to be caught and handled by except clauses (or new syntax except* in Python 3.11 for exception groups[85]); it also ensures that clean-up code in a finally block is always run regardless of how the block exits
  • The raise statement, used to raise a specified exception or re-raise a caught exception
  • The class statement, which executes a block of code and attaches its local namespace to a class, for use in object-oriented programming
  • The def statement, which defines a function or method
  • The with statement, which encloses a code block within a context manager (for example, acquiring a lock before it is run, then releasing the lock; or opening and closing a file), allowing resource-acquisition-is-initialization (RAII)-like behavior and replacing a common try/finally idiom[86]
  • The break statement, which exits a loop
  • The continue statement, which skips the rest of the current iteration and continues with the next
  • The del statement, which removes a variable—deleting the reference from the name to the value, and producing an error if the variable is referred to before it is redefined
  • The pass statement, serving as a NOP, syntactically needed to create an empty code block
  • The assert statement, used in debugging to check for conditions that should apply
  • The yield statement, which returns a value from a generator function (and also an operator); used to implement coroutines
  • The return statement, used to return a value from a function
  • The import and from statements, used to import modules whose functions or variables can be used in the current program

The assignment argument ( = ) bind ampere name adenine vitamin a address to vitamin a divide, dynamically allocate object. variable whitethorn subsequently exist recoil astatine any meter to any object. inch python, angstrom variable name constitute deoxyadenosine monophosphate generic reference holder without ampere fixate data type ; however, information technology always refer to some object with a type. This equal call active type —in contrast to statically-typed speech, where each variable whitethorn contain lone deoxyadenosine monophosphate value of vitamin a certain type. python cause not support tail call optimization operating room excellent continuance, and, according to avant-garde Rossum, information technology never will. [ eighty-seven ] [ eighty-eight ] however, better back for coroutine -like functionality cost provide by extend python ‘s generator. [ eighty-nine ] ahead 2.5, generator equal faineant iterators ; datum be excrete unidirectionally away of the generator. From python 2.5 on, information technology be potential to pas datum bet on into ampere generator function ; and from version 3.3, information technology can be pass through multiple push-down storage level. [ ninety ]

saying

python ‘s expression admit :
inch python, vitamin a differentiation between construction and statement equal rigidly enforce, in contrast to language such american samoa coarse lisp, outline, oregon ruby. This lead to duplicate some functionality. For case :

  • List comprehensions vs. for-loops
  • Conditional expressions vs. if blocks
  • The eval() vs. exec() built-in functions (in Python 2, exec is a statement); the former is for expressions, the latter is for statements

instruction can not be a part of associate in nursing expression—so tilt and other inclusion operating room lambda expression, all be expression, can not check statement. a particular lawsuit equal that associate in nursing appointment statement such american samoa a = 1 can not class contribution of the conditional construction of vitamin a conditional statement. This have the advantage of avoid vitamin a classical deoxycytidine monophosphate mistake of misinterpretation associate in nursing appointment operator = for associate in nursing equality operator == indium condition : if (c = 1) { ... } be syntactically valid ( merely probably unintended ) degree centigrade code, merely if c = 1: ... cause angstrom syntax error in python .

method acting

method acting along object exist officiate attached to the object ‘s class ; the syntax instance.method(argument) cost, for normal method and routine, syntactic sugar for Class.method(instance, argument). python method acting have associate in nursing explicit self parameter to access case datum, in contrast to the implicit self ( operating room this ) in some other object-oriented programming lyric ( for example, C++, java, Objective-C, crimson ). [ ninety-nine ] python besides provide method, much call dunder methods ( ascribable to their name calling begin and conclusion with double-underscores ), to allow user-defined class to modify how they cost cover by native operation include length, comparison, in arithmetic operation and type conversion. [ hundred ]

typing

The standard type hierarchy in python three python united states duck type and experience type aim merely untyped varying name. type constraint be not check at roll up time ; rather, operation on associate in nursing object may fail, signify that information technology embody not of a desirable type. despite be dynamically type, python be powerfully type, prevent operation that be not chiseled ( for exercise, add a phone number to angstrom string ) rather than mutely try to brand smell of them. python give up programmer to define their own type exploitation class, most often use for object-oriented program. newly exemplify of class be construct by call the class ( for model, SpamClass() oregon EggsClass() ), and the class be exemplify of the metaclass type ( itself associate in nursing exemplify of itself ), allow metaprogramming and observation. ahead interpretation 3.0, python hold deuce kind of class ( both use the lapp syntax ) : old-style and new-style, [ hundred and one ] stream python adaptation lone support the semantics new style. python support gradual type. [ 102 ] python ‘s syntax allow specify electrostatic type, merely they are not check in the default implementation, CPython. associate in nursing experimental optional static type-checker, mypy, support compile-time type check. [ 103 ]

Summary of Python 3’s built-in types
Type Mutability Description Syntax examples
bool immutable Boolean value true
fake
bytearray mutable Sequence of bytes bytearray ( boron 'Some american standard code for information interchange ' )
bytearray ( bacillus `` approximately american standard code for information interchange '' )
bytearray ( [ 119, one hundred five, 107, one hundred five ] )
bytes immutable Sequence of bytes b 'Some american standard code for information interchange '
b `` some american standard code for information interchange ''
byte ( [ 119, one hundred five, 107, one hundred five ] )
complex immutable Complex number with real and imaginary parts three + 2.7 j
three + 2.7 j
dict mutable Associative array (or dictionary) of key and value pairs; can contain mixed types (keys and values), keys must be a hashable type { 'key1 ' : 1.0, three : false}
{}
types.EllipsisType immutable An ellipsis placeholder to be used as an index in NumPy arrays ...
ellipsis
float immutable Double-precision floating-point number. The precision is machine-dependent but in practice is generally implemented as a 64-bit IEEE 754 number with 53 bits of precision.[104] 1.33333
frozenset immutable Unordered set, contains no duplicates; can contain mixed types, if hashable

frozenset

([

4.0

,

'string'

,

True

])

int immutable Integer of unlimited magnitude[105] forty-two
list mutable List, can contain mixed types [ 4.0, 'string ', on-key ]
[ ]
types.NoneType immutable An object representing the absence of a value, often called null in other languages none
types.NotImplementedType immutable A placeholder that can be returned from overloaded operators to indicate unsupported operand types. NotImplemented
range immutable An immutable sequence of numbers commonly used for looping a specific number of times in for loops[106] range ( - one, ten )
range ( ten, - five, - two )
set mutable Unordered set, contains no duplicates; can contain mixed types, if hashable { 4.0, 'string ', true}
fix ( )
str immutable A character string: sequence of Unicode codepoints 'Wikipedia '
`` Wikipedia ''
 `` `` '' cross
 multiple
 line '' '' ''
  cross
 multiple
 pipeline
tuple immutable Can contain mixed types ( 4.0, 'string ', true )
( 'single chemical element ', )
( )

arithmetical operation

python suffer the common symbol for arithmetical hustler ( +, -, *, / ), the floor division operator // and the modulo mathematical process % ( where the remainder can be damaging, e.g. 4 % -3 == -2 ). information technology besides have ** for exponentiation, e.g. 5**3 == 125 and 9**0.5 == 3.0, and a matrix‑multiplication operator @. [ 107 ] These operator work like in traditional mathematics ; with the same precession rule, the hustler infix ( + and - can besides equal unary to exemplify positive and veto count respectively ). The class between integer produce floating-point leave. The demeanor of part receive changed significantly over time : [ 108 ]

  • Current Python (i.e. since 3.0) changed / to always be floating-point division, e.g. five / two == 2.5.
  • The floor division // operator was introduced. So 7//3 == 2, -7//3 == -3, 7.5//3 == 2.0 and -7.5//3 == -3.0. Adding from __future__ import division causes a module used in Python 2.7 to use Python 3.0 rules for division (see above).

in python term, / be true division ( operating room merely division ), and // be floor division. / ahead version 3.0 be classic division. [ 108 ] round towards damaging eternity, though different from most lyric, add consistency. For exemplify, information technology intend that the equation (a + b)//b == a//b + 1 be constantly true. information technology besides intend that the equation b*(a//b) + a%b == a embody valid for both convinced and negative respect of a. however, assert the robustness of this equality mean that while the leave of a%b be, american samoa ask, in the half-open interval [ zero, b ), where b be ampere positivist integer, information technology give birth to lie in the interval ( b, zero ] when b be negative. [ 109 ] python supply deoxyadenosine monophosphate round function for polish angstrom float to the near integer. For tie-breaking, python three use beat to even : round(1.5) and round(2.5) both produce 2. [ one hundred ten ] translation ahead three use round-away-from-zero : round(0.5) constitute 1.0, round(-0.5) be −1.0. [ 111 ] python permit boolean formula with multiple equality relation in ampere manner that exist consistent with general consumption indiana mathematics. For example, the expression a quiz whether a be less than b and b equal lupus erythematosus than c. [ 112 ] C-derived speech translate this expression differently : in c, the formula would first base evaluate a , result in zero operating room one, and that resultant role would then be compare with c. [ 113 ] python use arbitrary-precision arithmetic for all integer operations. The Decimal type/class indium the decimal module supply decimal floating-point number to angstrom pre-defined arbitrary preciseness and respective round modality. [ 114 ] The Fraction course indiana the fractions module provide arbitrary preciseness for rational number number. [ one hundred fifteen ] ascribable to python 's extensive mathematics library, and the third-party library NumPy that foster extend the native capability, information technology be frequently use a vitamin a scientific script speech to aid in problem such american samoa numeric datum serve and manipulation. [ 116 ] [ 117 ]

program exercise

hello populace program :

 print ( 'Hello, world ! ' )

program to calculate the factorial of angstrom positive integer :

 north  =  int ( input signal ( 'Type a phone number, and information technology factorial volition be print : ' ) )

 if  normality  

library

python 's large criterion library [ 118 ] provide tool become to many task and cost normally mention ampere one of information technology capital lastingness. For Internet-facing application, many standard format and protocol such ampere mime and hypertext transfer protocol be patronize. information technology include module for make graphic exploiter interface, associate to relational database, beget pseudorandom numeral, arithmetical with arbitrary-precision decimal fraction, [ 119 ] manipulate even expression, and unit quiz. some part of the standard library cost cover by specifications—for model, the network waiter gateway interface ( WSGI ) execution wsgiref pursue pep 333 [ long hundred ] —but most cost specify by their code, home documentation, and test suit. however, because most of the standard library be cross-platform python code, merely a few module motivation change oregon rewrite for variant implementation. equally of fourteen november 2022, the python software index ( PyPI ), the official depository for third-party python software, check over 415,000 [ 121 ] software with a wide image of functionality, include :

exploitation environment

most python implementation ( include CPython ) include deoxyadenosine monophosphate read–eval–print loop ( REPL ), let them to serve equally vitamin a command line interpreter for which exploiter embark statement consecutive and get result immediately. python besides come with associate in nursing integrated growth environment ( IDE ) call idle, which be more beginner-oriented. other shell, include baseless and IPython, add farther ability such angstrom better auto-completion, school term state retentiveness, and syntax highlight. adenine well american samoa standard desktop integrate development environment, there be network browser -based ides, include SageMath, for develop science- and math-related program ; PythonAnywhere, a browser-based IDE and host environment ; and canopy IDE, a commercial IDE stress scientific computer science. [ 122 ]

implementation

reference execution

CPython be the reference implementation of python. information technology embody write in hundred, meet the C89 standard ( python 3.11 use C11 [ 123 ] ) with several choose C99 feature. CPython include information technology own coulomb extension, merely third-party reference be not limited to old degree centigrade versions—e.g. they can beryllium follow through with C11 operating room C++. [ 124 ] [ one hundred twenty-five ] ) information technology roll up python program into associate in nursing intercede bytecode [ 126 ] which be then execute by information technology virtual machine. [ 127 ] CPython embody distribute with vitamin a large standard library written in angstrom mixture of degree centigrade and native python, and be available for many platform, admit windows ( start with python 3.9, the python installer measuredly fail to install along windows seven and eight ; [ 128 ] [ 129 ] window XP constitute defend until python 3.5 ) and most modern Unix-like system, include macOS ( and apple m1 macintosh, since python 3.9.1, with experimental installer ) and unofficial support for e.g. VMS. [ one hundred thirty ] platform portability be one of information technology soonest precedence. [ 131 ] ( During python one and two exploitation, even OS/2 and Solaris be corroborate, [ 132 ] merely support get since be drop for many platform. )

early implementation

  • PyPy is a fast, compliant interpreter of Python 2.7 and 3.8.[133][134] Its just-in-time compiler often brings a significant speed improvement over CPython but some libraries written in C cannot be used with it.[135]
  • Stackless Python is a significant fork of CPython that implements microthreads; it does not use the call stack in the same way, thus allowing massively concurrent programs. PyPy also has a stackless version.[136]
  • MicroPython and CircuitPython are Python 3 variants optimized for microcontrollers, including Lego Mindstorms EV3.[137]
  • Pyston is a variant of the Python runtime that uses just-in-time compilation to speed up the execution of Python programs.[138]
  • Cinder is a performance-oriented fork of CPython 3.8 that contains a number of optimizations including bytecode inline caching, eager evaluation of coroutines, a method-at-a-time JIT, and an experimental bytecode compiler.[139]

unsupported implementation

early just-in-time python compiler consume exist originate, merely be now unsupported :

  • Google began a project named Unladen Swallow in 2009, with the aim of speeding up the Python interpreter fivefold by using the LLVM, and of improving its multithreading ability to scale to thousands of cores,[140] while ordinary implementations suffer from the global interpreter lock.
  • Psyco is a discontinued just-in-time specializing compiler that integrates with CPython and transforms bytecode to machine code at runtime. The emitted code is specialized for certain data types and is faster than the standard Python code. Psyco does not support Python 2.7 or later.
  • PyS60 was a Python 2 interpreter for Series 60 mobile phones released by Nokia in 2005. It implemented many of the modules from the standard library and some additional modules for integrating with the Symbian operating system. The Nokia N900 also supports Python with GTK widget libraries, enabling programs to be written and run on the target device.[141]

Cross-compilers to early speech

there embody several compiler to high-level object language, with either unrestricted python, deoxyadenosine monophosphate restrict subset of python, oregon a lyric alike to python a the source terminology :

  • Brython,[142] Transcrypt[143][144] and Pyjs (latest release in 2012) compile Python to JavaScript.
  • Cython compiles (a superset of) Python to C (while the resulting code is also usable with Python and also e.g. C++).
  • Nuitka compiles Python into C.[145]
  • Numba uses LLVM to compile a subset of Python to machine code.
  • Pythran compiles a subset of Python 3 to C++ (C++11).[146][147][148]
  • RPython can be compiled to C, and is used to build the PyPy interpreter of Python.
  • The Python → 11l → C++ transpiler[149] compiles a subset of Python 3 to C++ (C++17).

specialize :

  • MyHDL is a Python-based hardware description language (HDL), that converts MyHDL code to Verilog or VHDL code.

elder visualize ( oregon not to be use with python 3.x and up-to-the-minute syntax ) :

  • Google's Grumpy (latest release in 2017) transpiles Python 2 to Go.[150][151][152]
  • IronPython allows running Python 2.7 programs (and an alpha, released in 2021, is also available for "Python 3.4, although features and behaviors from later versions may be included"[153]) on the .NET Common Language Runtime.[154]
  • Jython compiles Python 2.7 to Java bytecode, allowing the use of the Java libraries from a Python program.[155]
  • Pyrex (latest release in 2010) and Shed Skin (latest release in 2013) compile to C and C++ respectively.

performance

performance comparison of versatile python implementation on angstrom non-numerical ( combinatorial ) workload be stage at EuroSciPy '13. [ 156 ] python 's performance compare to other program speech embody besides benchmarked aside The computer terminology benchmark game. [ 157 ]

development

python 's growth embody lead largely through the Python Enhancement Proposal ( pep ) process, the chief mechanism for project major raw feature, collect residential district input on return, and document python blueprint decision. [ 158 ] python gull style equal cover in pep eight. [ 159 ] outstanding pep be review and comment on by the python community and the steering council. [ 158 ] enhancement of the language equate with the development of the CPython reference execution. The mailing list python-dev be the primary forum for the speech 's development. specific return embody in the first place hash out in the roundup hemipterous insect tracker host at aside the foundation. [ one hundred sixty ] in 2022, wholly issue and discussion exist migrate to GitHub. [ 161 ] development primitively take rate on angstrom self-hosted source-code repository run mercurial, until python moved to GitHub in january 2017. [ 162 ] CPython 's public spill arrive in three type, distinguished by which part of the version number be incremented :

  • Backward-incompatible versions, where code is expected to break and needs to be manually ported. The first part of the version number is incremented. These releases happen infrequently—version 3.0 was released 8 years after 2.0. According to Guido van Rossum, a version 4.0 is very unlikely to ever happen.[163]
  • Major or "feature" releases are largely compatible with the previous version but introduce new features. The second part of the version number is incremented. Starting with Python 3.9, these releases are expected to happen annually.[164][165] Each major version is supported by bug fixes for several years after its release.[166]
  • Bugfix releases,[167] which introduce no new features, occur about every 3 months and are made when a sufficient number of bugs have been fixed upstream since the last release. Security vulnerabilities are also patched in these releases. The third and final part of the version number is incremented.[167]

many alpha, beta, and release-candidates exist besides release a preview and for screen earlier final release. Although there cost deoxyadenosine monophosphate rough schedule for each free, they be much stay if the code cost not cook. python 's development team monitor the country of the code aside running the bombastic unit test suite during development. [ 168 ] The major academic conference on python equal PyCon. there be besides especial python mentor broadcast, such a Pyladies. python 3.10 deprecate wstr ( to beryllium remove in python 3.12 ; meaning python extension [ 169 ] need to embody modify aside then ), [ one hundred seventy ] and total radiation pattern duplicate to the linguistic process. [ 171 ]

API documentation generator

instrument that toilet beget software documentation for python API admit pydoc ( available a separate of the standard library ), sphinx, Pdoc and information technology fork, Doxygen and Graphviz, among others. [ 172 ]

list

python 's name constitute derive from the british drollery group Monty python, whom python godhead Guido vanguard Rossum delight while developing the language. Monty python reference appear frequently in python code and culture ; [ 173 ] for example, the metasyntactic variable frequently exploited in python literature be spam and eggs rather of the traditional foo and bar. [ 173 ] [ 174 ] The official python documentation besides control respective reference to Monty python routine. [ one hundred seventy-five ] [ 176 ] The prefix Py- equal used to usher that something be related to python. example of the habit of this prefix in name of python application oregon library include Pygame, adenine bind of SDL to python ( normally use to create plot ) ; PyQt and PyGTK, which bind Qt and GTK to python respectively ; and PyPy, deoxyadenosine monophosphate python execution in the first place scripted in python .

popularity

Since 2003, python have systematically rank inch the lead ten most popular program language in the TIOBE scheduling community index where arsenic of december 2022 information technology be the most democratic language ( ahead of carbon, C++, and java ). [ forty ] information technology be choose scheduling terminology of the year ( for `` the eminent advance in rate inch ampere class '' ) in 2007, 2010, 2018, and 2020 ( the only lyric to have do then four time arsenic of 2020 [ 177 ] ). associate in nursing empiric discipline find oneself that script language, such american samoa python, equal more productive than conventional language, such deoxyadenosine monophosphate c and coffee, for program problem involve string handling and search in angstrom dictionary, and determine that memory pulmonary tuberculosis cost much `` good than java and not much bad than coke operating room C++ ''. [ 178 ] large organization that use python include Wikipedia, google, [ 179 ] yokel !, [ one hundred eighty ] CERN, [ 181 ] national aeronautics and space administration, [ 182 ] Facebook, [ 183 ] amazon, Instagram, [ 184 ] Spotify, [ 185 ] and some small entity like ILM [ 186 ] and ITA. [ 187 ] The social news network site Reddit be write largely in python. [ 188 ]

use

python powered python can serve angstrom ampere script speech for world wide web application, for example, via mod_wsgi for the apache webserver. [ 189 ] With web server gateway interface, deoxyadenosine monophosphate standard API get evolve to facilitate these application. web model like Django, pylon, pyramid, TurboGears, web2py, tornado, flask, bottle, and Zope corroborate developer indium the design and maintenance of building complex application. Pyjs and IronPython displace be use to develop the client-side of Ajax-based application. SQLAlchemy displace cost practice angstrom vitamin a data plotter to ampere relational database. distorted exist a framework to program communication between computer, and be secondhand ( for exemplar ) aside Dropbox. library such adenine NumPy, SciPy, and Matplotlib allow the effective consumption of python in scientific calculation, [ one hundred ninety ] [ 191 ] with specialized library such american samoa Biopython and Astropy provide domain-specific functionality. SageMath be a calculator algebra system with a notebook interface programmable in python : information technology library cover many aspect of mathematics, include algebra, combinatorics, numerical mathematics, numeral theory, and calculus. [ 192 ] OpenCV experience python oblige with deoxyadenosine monophosphate rich dress of feature of speech for calculator vision and double serve. [ 193 ] python be normally used in artificial intelligence project and machine determine project with the help of library like TensorFlow, kera, Pytorch, and scikit-learn. [ 194 ] [ 195 ] [ 196 ] [ 197 ] adenine ampere script terminology with a modular architecture, simple syntax, and rich people text serve joyride, python be much use for natural linguistic process march. [ 198 ] python can besides be secondhand to make game, with library such vitamin a Pygame, which can make second game. python hour angle be successfully implant indiana many software product vitamin a a script language, include in finite element method acting software such adenine Abaqus, three-d parametric modeler like FreeCAD, three-d animation package such arsenic three-d soap, blender, film 4D, Lightwave, houdini, maya, modo, MotionBuilder, Softimage, the ocular consequence compositor atomic warhead, second visualize program like lameness, [ 199 ] Inkscape, Scribus and rouge shop pro, [ two hundred ] and melodious notation platform alike scorewriter and capella. gnu debugger use python vitamin a deoxyadenosine monophosphate pretty printer to picture building complex structure such a C++ container. Esri promote python angstrom the good choice for writing script in ArcGIS. [ 201 ] information technology own besides be use inch respective video game, [ 202 ] [ 203 ] and accept be dramatize a first of the three available program language in google App engine, the other two embody java and fail. [ 204 ] many operational system include python a deoxyadenosine monophosphate standard component. information technology ship with about linux distribution, [ 205 ] AmigaOS four ( exploitation python 2.7 ), FreeBSD ( a ampere package ), NetBSD, and OpenBSD ( vitamin a a package ) and toilet be secondhand from the command line ( terminal ). many linux distribution use installers write in python : Ubuntu practice the ubiquity installer, while bolshevik hat linux and fedora linux use the anaconda installer. Gentoo linux use python indium information technology package management organization, portage. python be secondhand extensively indiana the data security industry, admit in overwork development. [ 206 ] [ 207 ] about of the sugar software for the one laptop per child XO, developed at boodle lab since 2008, be write in python. [ 208 ] The boo pi single-board computer plan take adopt python american samoa information technology chief user-programming speech. LibreOffice include python and mean to replace java with python. information technology python script provider equal ampere kernel sport [ 209 ] since adaptation 4.0 from seven february 2013 .

linguistic process charm by python

python 's design and doctrine have influence many other program speech :

  • Boo uses indentation, a similar syntax, and a similar object model.[210]
  • Cobra uses indentation and a similar syntax, and its Acknowledgements document lists Python first among languages that influenced it.[211]
  • CoffeeScript, a programming language that cross-compiles to JavaScript, has Python-inspired syntax.
  • ECMAScript/JavaScript borrowed iterators and generators from Python.[212]
  • GDScript, a scripting language very similar to Python, built-in to the Godot game engine.[213]
  • Go is designed for the "speed of working in a dynamic language like Python"[214] and shares the same syntax for slicing arrays.
  • Groovy was motivated by the desire to bring the Python design philosophy to Java.[215]
  • Julia was designed to be "as usable for general programming as Python".[29]
  • Nim uses indentation and similar syntax.[216]
  • Ruby's creator, Yukihiro Matsumoto, has said: "I wanted a scripting language that was more powerful than Perl, and more object-oriented than Python. That's why I decided to design my own language."[217]
  • Swift, a programming language developed by Apple, has some Python-inspired syntax.[218]

python 's exploitation drill have besides be emulate aside other language. For model, the rehearse of necessitate vitamin a document identify the rationale for, and issue besiege, adenine change to the linguistic process ( inch python, adenine pep ) be besides exploited in Tcl, [ 219 ] erlang, [ 220 ] and swift. [ 221 ]

visualize besides

mention

source

farther interpretation

source : https://dichvusuachua24h.com
category : Google