Program to print a triangle of numbers
You can do it with one loop that goes from a negative number to a positive, and create a string from a range calculated from the number:

int max = 5;
for (int i = 1 - max; i &lt; max; i++) {
  Console.WriteLine(String.Join(" ", Enumerable.Range(1, max - Math.Abs(i))));
}


That is of course actually two loops, the Range method will create numbers that the Join method loops through.