OwnValues

OwnValues[x]

gives the rule corresponding to any ownvalue defined for the symbol x.

Examples

open allclose all

Basic Examples  (1)

Set a value for x:

Display its ownvalues:

Scope  (2)

OwnValues returns rules corresponding to definitions made for symbols:

OwnValues can be used to set values directly:

Properties & Relations  (5)

Values can be defined by immediate or delayed assignments:

HoldPattern is used to protect the rules from their own definitions:

OwnValues has attribute HoldAll to protect against its argument's values:

Definition and Information display ownvalues but do not return them as values:

OwnValues returns a value that can be used in a program:

Evaluation of a symbol is equivalent to applying the rules for its definition:

Neat Examples  (1)

Copy a symbol's value to another symbol:

Wolfram Research (1991), OwnValues, Wolfram Language function, https://reference.wolfram.com/language/ref/OwnValues.html.

Text

Wolfram Research (1991), OwnValues, Wolfram Language function, https://reference.wolfram.com/language/ref/OwnValues.html.

BibTeX

@misc{reference.wolfram_2021_ownvalues, author="Wolfram Research", title="{OwnValues}", year="1991", howpublished="\url{https://reference.wolfram.com/language/ref/OwnValues.html}", note=[Accessed: 31-July-2021 ]}

BibLaTeX

@online{reference.wolfram_2021_ownvalues, organization={Wolfram Research}, title={OwnValues}, year={1991}, url={https://reference.wolfram.com/language/ref/OwnValues.html}, note=[Accessed: 31-July-2021 ]}

CMS

Wolfram Language. 1991. "OwnValues." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/OwnValues.html.

APA

Wolfram Language. (1991). OwnValues. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/OwnValues.html