Ternary for the win!
You deserve like the warmest hug ever
Without them I can put a '.' at the begining or end
So neat. Next time I will string multiple conditions together. Thanks for sharing!
Wow, this took some time. If you are having trouble understanding how it works, doing it manually on a piece of paper might help.
Didn't even know this was a thing. Here I am doing while loops like some kind of pleb haha
A switch is easier to read when you have more than 3 options. The compiler will generally create an optimised solution anyway (depending upon the compiler) so it is often better to write code that others can easily read.
The solution wasn't too hard, but the instructions were a little bit difficult to understand.
Thanks, great suggestion - without revealing the solution in any way! Helped me debug my code
This comment is hidden because it contains spoiler information about the solution
Lack of unsafe compiler option is not a kata issue, but it's related to Codewars code runner setup. If you think that setup of C# compiler needs to be changed, you can raise an issue at runner repo.
Said that, I am not really sure how inability of using pointers defeats purpose of the kata though. I would say it's quite contrary: attempt to use pointers to write C-like code in C# defeats purpose of why pointers were introduced to C#. Just the fact that you are writing a simulator of a machine which uses a pointer as an element of its architecture does not mean that BF pointer should translate into C# pointer. It can (in some very specific circumstances), but does not have to, and hardly ever should.
My C# solution works in Visual Studio. However I'm unable to get it working here because it does not allow compiling as unsafe. Unsafe is needed to use pointers in C#. I could make a work around that doesn't use pointers, but it feels like that would defeat the purpose of this Kata.