Question: In Javascript code create a FOR LOOP that outputs the numbers 1 3 5 7 9 with line breaks between each number. Display the output
In Javascript code create a FOR LOOP that outputs the numbers 1 3 5 7 9 with line breaks between each number. Display the output with a document.write statement. Also write a function called subtract that accepts two parameters, checks to see which value is larger, subtracts the smaller number from the larger number, and returns the difference. Use a prompt to ask for two numbers. Use the document.write statement to display the results.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
