Print alphabet pattern JavaScript JS program with flowchart and form values entered by user
Print alphabet pattern JavaScript JS program with flowchart and form values entered by user
In this tutorial, we will learn the followings;
- Flowchart of program of print alphabet pattern.
- Print alphabet pattern program.
- Print alphabet pattern program with form values entered by user.
Flowchart of program of print alphabet pattern.
Print alphabet pattern program.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | <!DOCTYPE html> <html> <head> </head> <body> <script> var alpha = "a"; for(var i=0; i<10; i++) { for (var j= 0; j<=i; j++) { document.write(alpha); } document.write("<br>"); } </script> </body> </html> |
Print alphabet pattern program with form values entered by user.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | <!DOCTYPE html> <html> <head> </head> <body> <script> var alpha = prompt("enter a number"); for(var i=0; i<10; i++) { for (var j=0; j<=i; j++) { document.write(alpha); } document.write("<br>"); } </script> </body> </html> |