Advertisement
Guest User

Untitled

a guest
Sep 25th, 2017
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. //Ex: 3,5 output ====> 15
  2. //Ex: 10,5 output ====> 50
  3.  
  4.  
  5.  
  6.  
  7.  
  8. const productOfTwoInt = (int,int2) => {
  9.  
  10. let result_one = 0;
  11. let reuslt_two = 0;
  12.  
  13. let final_result;
  14. let final_result2;
  15.  
  16. for(var x = 0; x <= int; x++){
  17. final_result = x += result_one
  18. console.log("what",final_result)
  19. }
  20.  
  21. for(var j = 0; j <= int2; j++){
  22. final_result2 = j += reuslt_two
  23. }
  24.  
  25. return final_result + final_result2
  26.  
  27. }
  28.  
  29. console.log(productOfTwoInt(3,5))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement