Tuesday, 24 July 2018

Accept User Values From Array

<html>
<head>
<h1> Accept user values from Array</h1>
</head>
<body>
<button onclick="display()">Display</button>

<script>
function display()
{

var n=0, i,j,a,r;
var arr1=[];

n=parseInt(prompt("Type how many numbers you would like to take"));
document.write("Entered Value are : "+"<br/>");


for(i=0;i<n;i++)
        {
          a=parseInt(prompt("Enter number " + (i+1)));
          arr1[i]=a;
          document.write(arr1[i]+ "<br/>");
        }
       
  }     
</script>
</body>
</html>

1 comment:

  1. Python is an open-source, high level, interpreted programming language which offers great opportunities for object-oriented programming. Choosing a python training program from Red Prism Group, which is best training institute for python in noida.

    ReplyDelete

Global Infrastructure and its components in AWS

You may operate your workloads wherever and however you choose with the AWS Global Infrastructure, and you'll use the same network, cont...