4 ms·
I don't know of a bar representation in a programming or data language. It requires either digit characters that have a bar, or the effect somehow produced via
by kazinator 1y ago
I don't know of a bar representation in a programming or data language. It requires either digit characters that have a bar, or the effect somehow produced via combining characters. Or else a multiline syntax where the coder has to prepare underscores over the digits in the previous line, and this is checked for alignment by the parser.
(We could think of other representations like 0.12'34 or something where the '34 indicates repeating digits. I've not seen that anywhere either, but it would be easy to implement.)
- taeric 1y agoI was assuming a BCD scheme to do something like this, at the binary level. At the text level, I'd assume parens to indicate the group would be common. Is what that Euler problem did, though; so I'm probably just biased on that. Actually getting the overbar, I wasn't too concerned with. Just noting that we have a way to do it on paper that doesn't require using ratios directly. Or infinite paper. :D At any rate, this also got me thinking about how to do operations on repeated digits. I'm assuming I would have learned something like this years ago, but I don't remember it. At all. I vaguely remember it was awkward to realize that 0.(9) == 1. But, I don't recall playing with that too much. Is neat to see you should be able to make the general ideas work out just fine after you account for that? Just widen any repeating groups so that they are the same size, and then add. Reduce using the 9 rule.