Write javascript code that prompts the user to enter a


Write 2 JavaScript codes as follows:

Note: Make sure you have your and tags as required to make sure your script can be displayed in a browser for testing purpose.

1) Write JavaScript code that prompts the user to enter a number, pass the number to a JavaScript function and let the function calculate and display the factorial of the number entered by the user.

2) Write JavaScript code that prompts the user to enter 10 numbers one at a time and stores each number as an element of an array of size 10. The program then prompts the user to enter another number, if the number entered matches with one of the numbers in the array, the program should display "Found", otherwise it should display "Not found" on the screen.

Solution Preview :

Prepared by a verified Expert
Basic Computer Science: Write javascript code that prompts the user to enter a
Reference No:- TGS02276262

Now Priced at $30 (50% Discount)

Recommended (90%)

Rated (4.3/5)