APPLY NOW HERE :: FREE REGISTERATION ONLINE
Want to know more about us and our multimedia, animation & web design courses, feel free to Contact Us. We would love to hear from you.
Loops can execute a block of code a number of times. if you want to run the same code over and over again, each time with a different value.
text += bikes[0] + "<br>";
text += bikes[1] + "<br>";
text += bikes[2] + "<br>";
text += bikes[3] + "<br>";
text += bikes[4] + "<br>";
text += bikes[5] + "<br>";
for (i = 0; i text +=bikes[i] + "
";
}
The for loop is often the tool you will use when you want to create a loop.
Syntax:
for(initializer; condition; iteration) { // Code to be executed }
The for loop requires following three parts.
The JavaScript for/in statement loops through the properties of an object:
var person = {fname:"John", lname:"Doe", age:25};
var text = "";
var x;
for (x in person) {
text += person[x];
}
Mobile Number :
9891 222 738,
9891 50 1300
E-mail : contactbapugraphics@gmail.com
ADDRESS: H-17 / 263, First Floor,Sector 7,
Near Rohini West Metro Station,
Opposite Metro Pillar No. 425
Rohini, Delhi - 110085
Day | Timing |
Monday To Friday | 8:00 Am To 7:00Pm |
Saturday | 10:00 Am To 6:00Pm |
Want to know more about us and our multimedia, animation & web design courses, feel free to Contact Us. We would love to hear from you.