COMP1001 More Text Processing
Requirement
This question prints the leaves of a symmetric tree. A user will be prompted for a symbol and a positive position for the tip of the leaves. Starting from the tip, the tree will fan out on both sides symmetrically until left side of the leaves reaches the left edge, assuming that the right edge has no limit. For example,
1 Please enter a symbol: *
2 Please enter a positive position
3 of the symbol on the first line: 10
4 *
5 ***
6 *****
7 *******
8 *********
9 ***********
10 *************
11 ***************
12 *****************
13 *******************