eval - Evaluate or Execute an Expression or Statements in JavaScript

eval function is used to evaluate or execute a dynamic expression. However, the security risks make eval, evil. So use it with great care.
<script type="text/javascript">

//Execute Statements
eval("x=5;y=4;document.write(x*y)");

//Evaluate an Expression
document.write("<br />" + eval("2+10"));

document.write("<br />" + eval(x+17));

</script>