suzen123
suzen123 suzen123
  • 04-01-2021
  • Computers and Technology
contestada

JAVA

Write a program to display the first ten terms of the series:
5, 10, 17, --------------​

Respuesta :

tonb
tonb tonb
  • 04-01-2021

Answer:

class Main {  

 public static void main(String args[]) {

   int a = 5;

   int delta = 5;

   for(int i=0; i<10; i++) {

       System.out.printf("%d, ", a);

       a += delta;

       delta += 2;

   }

 }

}

Answer Link

Otras preguntas

Give three examples of NON-TRADITIONAL web authoring tools 3 pour
The Persians allowed conquered kingdoms to keep their kings and traditions so long as they paid taxes to the Persian King. 1.True 2.False
who agrees with me? my aret btw
Select the two adverbs. The foreign exchange students from Russia join us for lunch quite regularly,​
2. From whom can you accept payment in a private club??. A club member B club member's spouse C ,guest of the club member D. None of the above​
Employment intervention means what.
lightning is an example of electrical energy true or false
A wider variety of goods available at cheaper prices may be a result of A. A decline in trade with other countries B. An increasing number of counties refusing
Abby takes her friend out to dinner and the Bill comes out to be $45.60 if she wants to leave a 15% tip. What would the amount of the tip be.
Music, like dance, evolved from man's kinship with nature, his reflections on the beauty & joy of wanting to imitate sounds. Explained pls.​