17:18
Developments in Muck! First, I realized that there was no point in golfing an already hard to read language, when I'm just trying to demo it. So I thought I'd show you how easy-to-read Muck can be! It looks really ugly put together, but separate it's really neat! So, here goes:
Fizzbuzz: A<3<5<<21+[>>>+(Fizz<<+>>)<+(Buzz<+>)<(<.>)[-]<+#]
Fizz: 6[+]. 9[+]. 26[+]. 26[+].
Buzz: 2[+]. 21[+]. 26[+]. 26[.]
Because 'FIZZ' are the 6th, 9th, 26th & 26th letters of the alphabet! Same with 'BUZZ'; 'B' is the second letter as expected
There's a little boilerplate to add, so the real thing is:
Fizz: >+6[+].9[+].26[+].26[+].-[-]<
Buzz: >>+2[+].21[+].26[+]..-[-]<<
Anyway, if you substitute the last Fizz/Buzz into the original I just sent, you get the full code! It'll definitely become even cleaner as I make the language more sleek. Some of that code could be made less clunky once the language is slightly evolved. But that's the prototype.
I share it with you because the other news is I finished a rough interpreter, so you can see this code in action on [TIO](https://tio.run/##rVZtb9s2EP5s/YqbjUASJLuxi6RbJwlIsnRNt75sTfbmGYYqUTExidIoCnVQ9LdnR1KyKdsJWmBfDJv33PG5517o6k6sSvb0PuNlAUmZ5yQRtGQ10KIquYCU/NsQy0ryuK7hguT5c2sQ59Uq/kBEaMPZ@cUPly9@fHn16qefX795@@6XX99f3/z2@x9//mVbg5RksFxSRsVy6dQkz1x0HsgvkyJeQwizk9PugOHPF3Fek@4gJ0IQXoe9w4bRpExJeKyDU5bsxGXghTDV1pTsW8cba1GmyupDsUur0Iik4XwbgBPRcIZXCqeNdQSdj9vRqRrDIaY1gct1QiqpqGO/KQVcFVVOCsIESSErOVxfvbVb77IRW2f8gURUfEUDMQOagamMhJm4ripzTe9o9myBCJJ3bq12hluy4m0uR9PZt/KKisv80OoDYWlod9w4qYnYEXNTWcSM4…
The '21' at the very beginning of the code just means to print the first 20 FizzBuzz numbers. You're welcome to try replacing that with anything and you'll get the first n-1.
Be sure to hide the header/footer in the TIO link, so you can play around with Muck in a cleaner environment
And let me know if you'd like a run down of the operators!
The parentheses are the main new ones though. They're like the inverse of [] and they just make a lot of Muck code cleaner:
[] : Run multiple times if cell doesn't equal 0
() : Run one time if cell does equal 0
Obviously the explanation for brackets is not very good. But I assume you know how they work from BF. The odd wording is to illustrate the differences from ()
The other one I added to simplify demos is '#' but it probably won't stay. It just prints a separator. You can set it in the code. For FizzBuzz I have sep = ', '
I won't cover 'A' because I don't want to make this too long to read. But basically, by default Muck is purely about numbers, and just prints the cell's value. A is what allows printing letters. It just loops through 26 letters of the alphabet, with space, ' ', being the 0 value. If you want the full ascii range like BF defaults, you set B. Each looping value must be set per cell though. So in this code, one cell is looping letters, one is looping booleans, one is looping 3 & one is looping 5
One last thing, if you don't mind a leading space, this can be done without using the cheaty `#` primitive in just two chars: [Click me](https://tio.run/##rVZtb9s2EP5s/YqbjUASJLuxi6RbJwlIsnRNt75sTfbmGYYqUTExidIoCnVQ9LdnR1KyKdsJWmBfDJv33PG5517o6k6sSvb0PuNlAUmZ5yQRtGQ10KIquYCU/NsQy0ryuK7hguT5c2sQ59Uq/kBEaMPZ@cUPly9@fHn16qefX795@@6XX99f3/z2@x9//mVbg5RksFxSRsVy6dQkz1x0HsgvkyJeQwizk9PugOHPF3Fek@4gJ0IQXoe9w4bRpExJeKyDU5bsxGXghTDV1pTsW8cba1GmyupDsUur0Iik4XwbgBPRcIZXCqeNdQSdj9vRqRrDIaY1gct1QiqpqGO/KQVcFVVOCsIESSErOVxfvbVb77IRW2f8gURUfEUDMQOagamMhJm4ripzTe9o9myBCJJ3bq12hluy4m0uR9PZt/KKisv80OoDYWlod9…
[Golfed](https://tio.run/##rVZtb9s2EP5s/YqbjUASJLuxi6RbJwlIsnRNt75sTfbmGYYqUTExidIoCnVQ9LdnR1KyKdsJWmBfDJv33PG5517o6k6sSvb0PuNlAUmZ5yQRtGQ10KIquYCU/NsQy0ryuK7hguT5c2sQ59Uq/kBEaMPZ@cUPly9@fHn16qefX795@@6XX99f3/z2@x9//mVbg5RksFxSRsVy6dQkz1x0HsgvkyJeQwizk9PugOHPF3Fek@4gJ0IQXoe9w4bRpExJeKyDU5bsxGXghTDV1pTsW8cba1GmyupDsUur0Iik4XwbgBPRcIZXCqeNdQSdj9vRqRrDIaY1gct1QiqpqGO/KQVcFVVOCsIESSErOVxfvbVb77IRW2f8gURUfEUDMQOagamMhJm4ripzTe9o9myBCJJ3bq12hluy4m0uR9PZt/KKisv80OoDYWlod9w4qYnYEXNTWcSM4KKpRdkKVwsUK1ntlhwFz/IyFs6Qsmzoug9UWkZoj5Yo236Q2bM912vetJ5tlg94npwedrVG8LrkBEiW0YRieeAjFSuoSpQDQW37X8eVlO@RthaICN…
Also, just had to share. I made a mistake in golfing it, and TIO printed this in my face:
1 2 FIZZ 4 BUTT FIZZ 7 8 FIZZ BUTT 11 FIZZ 13 14 FIZZBUTT 16 17 FIZZ 19 BUTT