Pages

Stars


Module stars_3
    Sub Main()
        Dim i, j, n As Integer
        Console.Write("Enter the number of lines:")
        n = CInt(Console.ReadLine())
        For i = 1 To n
            For j = 1 To n
                Console.Write(" * ")

            Next
            n -= 1
            Console.WriteLine()
        Next
        Console.ReadLine()
    End Sub
End Module
Output
* * * * *
* * * *
* * *
* *
*

No comments:

Post a Comment