Content deleted Content added
m remove Erik9bot category,outdated, tag and general fixes |
|||
Line 1:
{{Unreferenced stub|auto=yes|date=December 2009}}
In [[computer programming]], '''rank''' with no further specifications is usually a synonym for (or refers to) "number of dimensions"; thus, for instance, a bi-dimensional array has rank ''two'', a three-dimensional array has rank ''three'' and so on.
Strictly, no formal definition can be provided which applies to every [[programming language]], since each of them has its own concepts, [[Formal semantics of programming languages
In the case of [[APL programming language|APL]] the notion applies to every operand; and [[dyad
The box below instead shows how ''rank of a type'' and ''rank of an array expression'' could be defined (in a semi-formal style) for C++ and illustrates a simple way to calculate them at compile time.
Line 37 ⟶ 38:
:<source lang="cpp">sizeof(rankof(expr))</source>
==See also==
Line 43:
*[[Rank (J programming language)]], a concept of the same name in the [[J (programming language)|J programming language]]
{{DEFAULTSORT:Rank (Computer Programming)}}
{{compu-lang-stub}}▼
[[Category:Arrays]]
[[Category:Programming language topics]]
|