Jump to content

Wikifunctions:Type

From Wikifunctions

Every Object in Wikifunctions belongs to a Type. Types decide how Objects of that Type are structured, and what they mean. Types are also used to specify the Arguments of a Function, and what a Function returns.

Currently, there are 25 Types that are available for specifying the Arguments and the return Type of a Function:

  • String (Z6): A sequence of characters, and one of the fundamental Z4/Types available in the Wikifunctions system.
  • Boolean (Z40): Either 'true' or 'false', and is one of the fundamental Z4/Types available in the Wikifunctions system.
  • Typed list (Z881): A list containing items of the same type

Numeric types

  • Natural number (Z13518): an arbitrary-large whole number, either zero or positive
  • Sign (Z16659): The sign of a number
  • Integer (Z16683): arbitrarily large whole numbers, including negative ones and 0. 0 is the only value allowed to have a neutral sign (and it must have that sign; positive and negative 0 are possible but not valid)
  • Rational number (Z19677): a signed ratio of two Natural numbers (equivalent to a ratio of integers) not necessarily with the simplest representation

Calendar types

Gregorian calendar

Igbo calendar

Wikidata types

Wikidata entities

Wikidata references

Wikidata statements

Other types can be used but there may be bugs. For a list of all types, see the list of all types

New Types can be proposed on Wikifunctions:Type proposals.

See also