what is ^@ character in vi? what is ^@ character in vi? unix unix

what is ^@ character in vi?


As the comments say ^@ is actually a null byte (\x00) in your file.

If you want to get rid of all null byte instances then you can use this command in vi:

:%s/[\x0]//g


You can answer the question yourself: at least, the "what character is this" part, not the "how did it get here" part. From :help ga:

Print the ascii value of the character under thecursor in decimal, hexadecimal and octal.  Forexample, when the cursor is on a 'R':        <R>  82,  Hex 52,  Octal 122

For more details and related commands, see the full entry.