Advertisement
tei123

js

Dec 8th, 2016
398
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.47 KB | None | 0 0
  1. <html>
  2. <head>
  3. </head>
  4. <body>
  5. <script>
  6. var a,b,c,d,e;
  7. a=prompt("Liczba 1");
  8. b=prompt("Liczba 2");
  9. a=parseInt(a);
  10. b=parseInt(b);
  11. a=a*a;
  12. alert(a+" to kwadrat liczby nr1");
  13. var i;
  14.  
  15. if(b>0){
  16. for(i=0;i<=b;i++)
  17. {
  18. document.write(i+"<br>")
  19. };};
  20.  
  21. if(b==0)
  22. {alert("druga liczba jest rowna 0");
  23. };
  24.  
  25. var j;
  26. if(b<0)
  27. {
  28. for(j=0;j>=b;j--)
  29. {
  30. document.write(j+"<br>")
  31. };};
  32.  
  33.  
  34.  
  35.  
  36. </script>
  37. <br><br><br>
  38. Strona internetwowa
  39. <br>
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.  
  48. </body>
  49. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement