Encapsulation of an optional value in programming or type theory
For families of option contracts in finance, see Option style.
This article has multiple issues. Please help improve it or discuss these issues on the talk page. (Learn how and when to remove these template messages)
This article needs additional citations for verification. Please help improve this article by adding citations to reliable sources. Unsourced material may be challenged and removed. Find sources: "Option type" – news · newspapers · books · scholar · JSTOR(July 2019) (Learn how and when to remove this message)
This article possibly contains original research. Please improve it by verifying the claims made and adding inline citations. Statements consisting only of original research should be removed.(July 2019) (Learn how and when to remove this message)
(Learn how and when to remove this message)
In programming languages (especially functional programming languages) and type theory, an option type or maybe type is a polymorphic type that represents encapsulation of an optional value; e.g., it is used as the return type of functions which may or may not return a meaningful value when they are applied. It consists of a constructor which either is empty (often named None or Nothing), or which encapsulates the original data type A (often written Just A or Some A).
A distinct, but related concept outside of functional programming, which is popular in object-oriented programming, is called nullable types (often expressed as A?). The core difference between option types and nullable types is that option types support nesting (e.g. Maybe (Maybe String) ≠ Maybe String), while nullable types do not (e.g. String?? = String?).
(especially functional programming languages) and type theory, an optiontype or maybe type is a polymorphic type that represents encapsulation of an optional...
up option or options in Wiktionary, the free dictionary. Option or Options may refer to: Option key, a key on Apple computer keyboards Optiontype, a...
In finance, an option symbol is a code by which options are identified on an options exchange or a futures exchange. Before 2010, the ticker (trading)...
values of the data type. In statically typed languages, a nullable type is an optiontype[citation needed], while in dynamically typed languages (where...
corresponds to an enumerated type. One common ADT is the optiontype, defined in Haskell as data Maybe a = Nothing | Just a. Some types are very useful for storing...
the underlying is greater than K.) The most obvious use of a put option is as a type of insurance. In the protective put strategy, the investor buys enough...
an option is the class into which the option falls, usually defined by the dates on which the option may be exercised. The vast majority of options are...
of roles specified by the customer such as: General Purpose – default option (Type 31). Anti-air warfare – Leverages the existing anti-air capabilities...
A covered option is a financial transaction in which the holder of securities sells (or "writes") a type of financial options contract known as a "call"...
Lookback options, in the terminology of finance, are a type of exotic option with path dependency, among many other kind of options. The payoff depends...
In finance, a spread option is a type of option where the payoff is based on the difference in price between two underlying assets. For example, the two...
option is a financial exotic option in which the payoff is either some fixed monetary amount or nothing at all. The two main types of binary options are...
The possible options that can be put in the header are as follows: The table below shows the defined options for IPv4. The OptionType column is derived...
An Asian option (or average value option) is a special type of option contract. For Asian options, the payoff is determined by the average underlying price...
revoke an offer". Option contracts are common in relation to property (see below) and in professional sports. An option contract is a type of contract that...
to the optiontype in ML or the Maybe type in Haskell, and can be seen as a tagged pointer: a tagged union (with an encoded tag) of two types: Valid pointers...
A protective option or married option is a financial transaction in which the holder of securities buys a type of financial options contract known as a...
A Boston option, also known as a deferred premium option, is a type of American option. This type of option is considered a long-term option due to how...
Real options valuation, also often termed real options analysis, (ROV or ROA) applies option valuation techniques to capital budgeting decisions. A real...
right to sell a particular stock at the option's strike price. This is often done to gain exposure to a specific type of opportunity or risk while eliminating...
use of the Option key is similar to that of the AltGr key on European keyboards of IBM-compatible PCs, in the sense that it can be used to type additional...
this use of null pointers can be compared to nullable types and to the Nothing value in an optiontype. A null pointer should not be confused with an uninitialized...
In finance, a chooser option is a special type of option contract. It gives the purchaser a fixed period to decide whether the derivative will be a European...
optiontype constructor in OCaml, similar to the Maybe type in Haskell, augments a given data type to either return Some value of the given data type...