Write a short program that takes an integer value (call it n) from the user and prints out a triangle composed of O and X characters.
For example, if the user enters 3 as the input, your program should print out:
O
OX
O X O
If the user enters 5 as the input, your program should print out:
O
O X
O X O
O X O X
O X O X O
Sorry I couldn't give you some code that I have use to attempt this question. But I have no idea how to do this. Thanks a lot in advance :)