what character is a physical newline
Matthew Seaman
m.seaman at infracaninophile.co.uk
Mon Jun 29 05:57:13 UTC 2009
Aryeh M. Friedman wrote:
> Glen Barber wrote:
>> On Sun, Jun 28, 2009 at 10:21 PM, Aryeh M.
>> Friedman<aryeh.friedman at gmail.com> wrote:
>>
>>> I am writting a parser (tokenizes all characters among other things) and
>>> need to know what control char is equivelent to a newline (I do not need
>>> windows cross compatibility)
>>>
>>
>> What do you mean exactly? What language(s)? If I understand your
>> question correctly, the C / C++ / Java / PHP (and I think Perl)
>> 'newline' character is '\n'
>>
>>
> I meant what ascii character does \n actual correspond to (I assume <CR>
> but just making sure)
On Unix, the end of line character is NL (012 octal, 10 decimal, 0x0a hex) --
see ascii(7). Some people know it as Ctrl-J
Cheers,
Matthew
--
Dr Matthew J Seaman MA, D.Phil. 7 Priory Courtyard
Flat 3
PGP: http://www.infracaninophile.co.uk/pgpkey Ramsgate
Kent, CT11 9PW
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 259 bytes
Desc: OpenPGP digital signature
Url : http://lists.freebsd.org/pipermail/freebsd-questions/attachments/20090629/a3799e80/signature.pgp
More information about the freebsd-questions
mailing list