Strict programming language: Difference between revisions

Content deleted Content added
m Fixed broken links
Light current (talk | contribs)
hdgs
Line 1:
A '''strict programming language''' is one in which only [[strict function]]s may be defined by the user. A ''non-strict programming language'' is one which is not strict, and hence may allow [[lazy evaluation]].
 
== Examples ==
 
Nearly all [[programming language]]s in common use today are strict. Examples include [[C programming language|C]], [[C plus plus|C++]], [[Java programming language|Java]], [[Perl programming language|Perl]] (up through version 5), [[Python programming language|Python]], [[Ruby programming language|Ruby]], [[Common Lisp programming language|Common Lisp]], [[Scheme programming language|Scheme]], and [[ML programming language|ML]]. The best known non-strict languages are [[Haskell programming language|Haskell]], [[Miranda programming language|Miranda]], and [[Clean programming language|Clean]].
 
== Explanation ==
 
In most non-strict languages the non-strictness extends to [[algebraic data type|data constructor]]s. This allows conceptually infinite data structures (such as the list of all [[prime number]]s) to be manipulated in the same way as ordinary finite data structures. It also allows for the use of very large but finite data structures such as the complete [[game tree]] of [[chess]].