Computer Science, asked by devasurya2015, 7 hours ago

create a java script program to display numbers 1 to 25​

Answers

Answered by anindyaadhikari13
3

Solution.

The JavaScript co‎‎ de for the question is given below -

\rule{200}{2}

for(var i=1;i<=25;i++)

    document.write(i+" ");

\rule{200}{2}

Note: You have to write the co‎‎ de inside script tag.

Logic.

  • Run a loop from i = 1 to 25.
  • Display the value of i.

See attachment for output.

Attachments:
Similar questions