0

for the single line command challenge:

Console.WriteLine("        1\n      121\n    12321\n  1234321\n123454321\n  1234321\n    12321\n      121\n        1");

Of course that violates the "using a loop" constraint :)

0

Of course you could get a single line instruction and use a loop by preceeding the above with
for (; 1 == 2; ) ;
You can make it a single line in a loop with:
for (int i=0; i < 1; i++)

Edited by kplcjl

0

What was it my professor once said, it's now how efficent you write the code, it's how easy it is to maintain ... LOL

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.