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

what literary nonfiction has in common with fiction.
How can you use formulas you already know to find the area and perimeter of a composite figure? The six lane track shown in the made up of a rectangle. Termi
How do you think the Lewis and Clark expedition might have been different if Sacajawea had joined the group
Flower position is an example of which of the following? A) Character B) Genotype C) Trait
y-1/4x=-1 y-2=4x one solution, no solution or infinite solution?
PLEASE ANSWER QUICKLY
is this true of false ?? please help
Vic has 3 pairs of pants: brown, black, and gray. He has 3 dress shirts: white, black, and stripped. He can also wear a green or black tie
In the early 1800s, which major North American river were many American settlers using for trade? Amazon River Mackenzie River Mississippi River St. Lawrenc
best university for IT