1.0k views
0 votes
Write a program using for loop to find the cube of numbers from 50-100
FASTT

1 Answer

2 votes

Answer:

JAVA

for(int i = 50; i <= 100 i++;)

{

int cubedNum = Math.pow(i, 4);

System.out.println(cubedNum);

}

Step-by-step explanation:

The For loop is set so that it will go the amount of times until the variable i reaches 100, then it will stop increasing i.

Then, we raise i to the 4th power in the loop, and then print it out.

#teamtrees #PAW (Plant And Water)

User Sasha Kos
by
8.2k points

Related questions

asked May 15, 2024 108k views
Chitranna asked May 15, 2024
by Chitranna
7.6k points
2 answers
0 votes
108k views
asked Aug 6, 2024 112k views
Tyson Phalp asked Aug 6, 2024
by Tyson Phalp
7.3k points
1 answer
4 votes
112k views