\1 Glitch

Working on “The two piles difference” community puzzle and this error pops up when I try to compile my C program.

Errors
/tmp/Answer.c: In function ‘permute’:
/tmp/Answer.c:129:5: error: stray ‘\1’ in program
for (int i=0; i<=list[level].count; i++)
^

I wouldn’t bother you about it, but it’s the second time it has happened. I fixed it the last time by re-typing the offending line.

I have no idea how a \1 character got entered, hence I call it a glitch.

Did you copy-paste the code?

I copied the error message with the offending line, but not the original code. This problem hasn’t shown up again, so I’m not going to worry about it. Besides I have other problems to worry about now.

New problem, new glitch.

Errors
/tmp/Answer.c:35:1: error: stray ‘\1’ in program
item_type* additem(char* s)
^

Original line copied from program:

item_type* additem(char* s)

This time I am working on the Longest Palindrome community puzzle.

Here we go again:

Errors
/tmp/Answer.c: In function ‘main’:
/tmp/Answer.c:43:5: error: stray ‘\1’ in program
fgetc(stdin);
^
This time I am working on the Turing machine community puzzle.

I think you somehow got an unreadable character into your source code. Maybe something went wrong when you copy/pasted something from a website. Character 5 on line 43. Try to delete the line and retype it.

Retyping the line fixed it. Hard to see how the bad character got it there, it was one of the original lines from the template. Or maybe it’s because I put a newline before the fgetc.

Fixed one line and boom, the same problem shows up on another. Fixed it the same way. I might have to reboot (oh no!).

char    tape[T + 1];