Home > front end >  How to achieve this
How to achieve this

Time:11-04




<meta charset="utf-8"/& gt;
What can you do return value & lt;/title> <br/></head> <br/><body> <br/><The script type="text/javascript" & gt; <br/>//add code here <br/>The function calculate (num1, num2) {<br/>Return the function add (num1, num2) {<br/>[num1 + num2]; <br/>} <br/>Return the function subtract (num1, num2) {<br/>[num1 - num2]; <br/>} <br/>Return the function multiply (num1, num2) {<br/>[num1 * num2]; <br/>} <br/>Return the function divide (num1, num2) {<br/>Num1/num2; <br/>} <br/>} <br/>The console. The log (calculate (5, 2) (5, 2)); <br/></script> <br/></body> <br/></html> <br/><strong> I why the return value is undefined, and how to realize the arithmetic, return will exit function? </strong><p class="article - content rp"> CodePudding user response: </p><img SRC="https://img.codepudding.com/202011/158831041002312.gif" Alt=""/>, this is you practice, the old so you ask, you don't want to, not to find basic information online, useful to you? </div> <div class="th_page th_page_color"></div> <div class="umCopyright"> <p>Page link:<a href="/frontend/77267.html" target="_blank" style="color:#999">https//www.codepudding.com/frontend/77267.html</a></p> </div> <div class="detail-arr"> <div class="detail-arr-left">Prev:<a href='/frontend/77266.html'>Vue flowplayer how to use</a></div> <div class="detail-arr-right">Next:<a href='/frontend/77268.html'>This code in webstorm background color in the picture, please cover how to set the cancel</a></div> </div> </div> </div> </div> </div> <div class="container th_top"> <div class="row"> <div class="col-md-12"> <div class="hot-tags neitags"> <ul> <li><i class="iconfont icon-x-tags"></i> Tags:  </li> <a href='/e/tags/?tagname=JavaScript' target='_blank'>JavaScript</a> </ul> </div> </div> </div> </div> <div class="container th_top"> <div class="row"> <div class="col-md-12"> <div class="xiangguan"> <ul class="msg msghead"> <li class="tbname">Related</li> </ul> <ul> </ul> </div> </div> </div> </div> <div class="container th_top"> <div class="row"> <div class="col-md-12"> <div class="flinks"> <ul> <li><i class="iconfont icon-x-tags"></i> Links:  </li> <li class="liflinks"><a target="_blank" href="/" title="CodePudding">CodePudding</a></li> </ul> </div> </div> </div> </div> <div class="footer"> <p><span style="font-size:16px;color:#666;font-weight: bold">About Us:</span>  <a href="https://www.codepudding.com/contact.html">Contact Us</a>      <a href="https://www.codepudding.com/service.html">Terms of Service</a>      <a href="https://www.codepudding.com/privacy.html"> Privacy Policy</a></p> <p class="foot_info">Copyright © 2010-2023,Powered By <a href="/" target="_blank">CodePudding</a> </p> </div> <script type="text/javascript" src="/skin/code/tianhu.js"></script> </body></html>