answersLogoWhite

0


Best Answer

system.out.println(" print 1-100 numbers");

for(i=0;i<=100;i++)

system.out.println(i);

o/p1

2

3

4

5

.......

User Avatar

Wiki User

14y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Sample code of loops and repetitions?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

What looping structures are there in JavaScript?

Loops in Java Script are:for - loops through a block of code a specified number of timeswhile - loops through a block of code while a specified condition is truedo...while - also loops through a block of code while a specified condition is truefor...in - loops through the properties of an objectFor more information, visit the Related Link.


In software programming the repetition of various steps is called?

Repetitive code is usually called a loop. Loops are usually iterative, however recursive loops are also possible.


How do you write a java code that executes or runs many times?

Use loops. int i; // for loop for(i = 0; i &lt; 10; ++i) { System.out.println(i); } // do loop i = 0; do { System.out.println(i++); } while(i &lt; 10); // while loop i = 0; while(i &lt; 10) { System.out.println(i++); } Each of the above blocks of code will print the values 0-9. Replace the body of the loops to make the code it executes useful. Replace the conditions to change when the loops exit.


What is definite loop?

Definite interations: Repeated sequence of calculations/ operations for a fixed number of repetitions. (Do or For loop) Indefinite iteration: no set limit on iterations, generally "while" loops. multiple interations is the same as multiple repetitions or trials.


What is the use of colon in python after loop and condition?

it starts a new code block. all the indented code after the colon will be considered as one block. for example, in loops it means that all the indented code after the colon will be run on each iteration. example: for i in range(4): # this code will run 4 times # this code will be ran once.

Related questions

How does the number of repetitions effect the shape of the normal distribution?

When we discuss a sample drawn from a population, the larger the sample, or the large the number of repetitions of the event, the more certain we are of the mean value. So, when the normal distribution is considered the sampling distribution of the mean, then more repetitions lead to smaller values of the variance of the distribution.


Froot loops upc code?

06483412


What looping structures are there in JavaScript?

Loops in Java Script are:for - loops through a block of code a specified number of timeswhile - loops through a block of code while a specified condition is truedo...while - also loops through a block of code while a specified condition is truefor...in - loops through the properties of an objectFor more information, visit the Related Link.


What is the difference between loops and functions?

LOOP: In loops reusability of the code is restricted to a specific area FUNCTION: In functions reusability of the code is not restricted to specific area.That means you can call the function code from any where in the program


Loops?

Runs a certain section of code a given number of times


What is a repetitions?

Repetitions is where you may do 5 repetitions of quats , this is where you do them 5 times. It just difrenciates how many times you do them.


What is the espin unlock code for the sample network?

Summer Sample: Health "Center"


What is a series of repetitions known as?

A series of repetitions is known as a set.


In software programming the repetition of various steps is called?

Repetitive code is usually called a loop. Loops are usually iterative, however recursive loops are also possible.


How do you write a java code that executes or runs many times?

Use loops. int i; // for loop for(i = 0; i &lt; 10; ++i) { System.out.println(i); } // do loop i = 0; do { System.out.println(i++); } while(i &lt; 10); // while loop i = 0; while(i &lt; 10) { System.out.println(i++); } Each of the above blocks of code will print the values 0-9. Replace the body of the loops to make the code it executes useful. Replace the conditions to change when the loops exit.


What is definite loop?

Definite interations: Repeated sequence of calculations/ operations for a fixed number of repetitions. (Do or For loop) Indefinite iteration: no set limit on iterations, generally "while" loops. multiple interations is the same as multiple repetitions or trials.


How does C plus plus endeavor to represent the loop paradigm?

Iterative loops in C/C++ are represented by for(), while() and do...while() code blocks. Recursive loops are represented by functions calling themselves.