Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Exercise 5.3 Programming Principles Week 5
- using System;
- public class Triangle
- {
- public static void Main()
- {
- string input; int parse; int count = 0;
- Console.Write("Please senter the number of asterisks: ");
- input = Console.ReadLine();
- parse = int.Parse(input);
- for (int i = parse; count <= parse; count++)
- {
- string s = new string('*', count);
- Console.WriteLine(s);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement