Thanks for the explanation jsmith and helios :).
I was wondering about the notation of numbers using chars already because of the names of memory locations. I get it now, thanks.
I however still dont see that my method is less efficient. Yes, it does calculate more in a shorter 'matrix' (right way to use that word?), but it also has more information in it.
1 1 1 1
1 2 3 4
1 3 6 A
1 4 A K
Two reach the 10's the way you're using you would need a bigger matrix:
1 0 0 0 0 0
1 1 0 0 0 0
1 2 1 0 0 0
1 3 3 1 0 0
1 4 6 4 1 0
1 5 A A 5 1
Where the numbers in bold are unusable because they are only part of a line.
|
Wy wouldnt i be able to use those values? I would think my method is more effecient, because every element presents an actuall value, while in your method half of the elements hold zero.
Sorry that i keep asking, but I really want to understand this. Again: I dont think my method actually
is more efficient then yours, but i dont understand wy it is not.
EDIT: sorry, i see the problem. If you want to present the numbers as a triangle, you need to whole line, while i'm only calculating a part of it. So you cant use the numbers.
The reason i didnt saw this directly is because the first time I saw the pascal triangle it was presented in a square (wich can be really intresting to, eg if you draw a "*" everywhere the number is not even, and just " " if the number is even). I get it now, thanks for your explanations.