Sort three variables: Difference between revisions

Content added Content deleted
(Added Fōrmulæ solution)
Line 1,771: Line 1,771:
77444</pre>
77444</pre>


=={{header|Mathematica}}==
=={{header|Mathematica}}/{{header|Wolfram Language}}==
{{Output?}}
All variables in Mathematica are typeless so the follow code works in all cases
All variables in Mathematica are typeless so the follow code works in all cases
<lang Mathematica>{x, y, z} = Sort[{x, y, z}]</lang>
<lang Mathematica>{x, y, z} = Sort[{x, y, z}]</lang>
example:
<lang Mathematica>x = 77444;
y = -12;
z = 0;
{x, y, z} = Sort[{x, y, z}];
{x, y, z}</lang>
{{out}}
<pre>{-12, 0, 77444}</pre>


=={{header|min}}==
=={{header|min}}==