Computer Science, asked by sunitagupta54637, 1 year ago

WRITE A JAVASCRIPT CODE TO DISPLAY NATURAL NUMBER FROM 1 TO 10. Please answer the correct

Answers

Answered by ArchitPathak
0

public class Exercise10 {

public static void main(String[] args)

{

int i;

System.out.println ("The first 10 natural numbers are:\n");

for (i=1;i<=10;i++)

{

System.out.println (i);

}

System.out.println ("\n");

}

}

Plz Mark it as Brainliest

And follow me Plz

Answered by modi7260
0

Answer:

public class Exercise10 {

public static void main(String[] args)

{

int i;

System.out.println ("The first 10 natural numbers are:\n");

for (i=1;i<=10;i++)

{

System.out.println (i);

}

System.out.println ("\n");

}

}

Please mark it as brainliest.

Similar questions