Notice: Write your answer(s) in the corresponding textbox(es). Then save this form as a PDF file name FizzQuizz-loops-2.pdf
and send it as an attachment by email to msantos@dragonacademy.org. Subject: "Fizz Quizz".
P1) Check the following code. How many times will an alert be displayed?
for(var i=1; i<=10 ; i=i+1){
alert("This is step number "+i) ;
}
P2) Write a program to calculate the following sum of 10 terms:
1 + 2 * 2 + 3 * 22 + ... + 9 * 28 + 10 * 29
Notice: Make your program print the result using an alert window.
P3) What's the result of your program when you only sum the first 2 terms?
P4) What's the result of your program when you only sum the first 3 terms?