Template:Evalns

From MidsouthMakers - Memphis Area Hackerpace
Jump to navigation Jump to search
{{{{{subst|}}}#if:{{{{{subst|}}}#ifexpr:{{{{{subst|}}}#expr:{{{1}}}}}}}|({{{1}}})|{{{{{subst|}}}#expr:{{{1}}}}}}}

EVALuate, but No Scientific notation.

This template can be used to evaluate an expression, if the result has to be suitable as input for further expressions. If the output is not valid as input, the expression is just reproduced, enclosed in parentheses.

  • {{evalns|3*4}} gives 12.
  • {{evalns|1234567890*12}} gives 14814814680.
  • {{evalns|1234567890*1234567890}} gives 1.5241578750191E+18.
  • {{eval|2*{{evalns|1234567890*1234567890}}}} gives Template:Eval.