Sunday, April 5, 2020

javascript star pattern program 1

<html>
<head>
<title>javascript star pattern</title>
</head>
<body>
<script type="text/javascript">
var i,j;
for(i=1;i<=5;i++)
{
for(j=1;j<=i;j++)
{
document.write("*");
}
document.write("<br>");
}
</script>
</body>
</html>


Output

No comments:

Post a Comment