[SOLVED] DSRN (dog slow roman numerals)
|
06-15-2014, 07:29 PM
Post: #39
|
|||
|
|||
RE: DSRN (dog slow roman numerals)
(06-15-2014 06:48 PM)Claudio L. Wrote: What would be a down side in your opinion? I have a problem with overloading + for operations that violate basic rules of addition. In the case of string concatenation it is the commutative property: "a" + "b" ≠ "b" + "a" For this operation another symbol should be used: . or ~ or ++ or whatever. It's the same with concatenating lists. But it gets worse with the "addition" of an element to a list. Why is { 1 2 3 } + 4 = { 1 2 3 4 } but { 5 6 7 } - 4 = { 1 2 3 }? But then 4 + { 1 2 3 } = { 5 6 7 }. And if you really want to add a number to each element you have to use ADD: { 1 2 3 } ADD 4 = { 5 6 7 } I still think this was the worst decision when designing RPL. Cheers Thomas |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 5 Guest(s)