@zhelih
Your english is barely readable, and the above post was your first post in this thread, what was your second point?
@asharrajpoot
I had an idea for another way to code the output. What if you built a string that contained the proper first line. (I'll build it manually, but you should probably use a loop.)
char masterline[80] = "A B C D E F G F E D C B A";
Then to print the table as you wanted:
Then you could walk through the row, outputting characters. If the character in the string is less than a limit (we will cover the limit ina second) you output the character, otherwise you output a space.
For the 1st row, print all characters <= 'G' (which would be all of them)
For the 2nd row, print all characters <='F' (all but the G)
For the 3rd row, print all characters <= 'E'
...
For the last row, print all characters <= 'A'
Would that be any easier?
The proposed algorithm would probably consume more CPU than what you're doing now, but I also suspect that both will run so fast you won't notice.