Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #49201

Re: newbie EOL while scanning string literal

Newsgroups comp.lang.python
Date 2013-06-25 15:37 -0700
References <da2378bb-e76b-4720-8071-784c717a8c38@googlegroups.com>
Message-ID <cb46c2b7-6374-46ec-8f72-6e69fcc8c1e6@googlegroups.com> (permalink)
Subject Re: newbie EOL while scanning string literal
From rurpy@yahoo.com

Show all headers | View raw


On Tuesday, June 25, 2013 4:19:43 PM UTC-6, willle...@gmail.com wrote:
>[...]
> na=('type first integer n\')##THE RED SHADOW APPEARS HERE##

You want \n at the end of the string, not n\.
A backslash character \ in front of the ' escapes the ' and 
causes it to to be considered as a character in the string
rather than ending the string. 

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

newbie EOL while scanning string literal willlewis965@gmail.com - 2013-06-25 15:19 -0700
  Re: newbie EOL while scanning string literal willlewis965@gmail.com - 2013-06-25 15:25 -0700
  Re: newbie EOL while scanning string literal Andrew Berg <robotsondrugs@gmail.com> - 2013-06-25 17:35 -0500
  Re: newbie EOL while scanning string literal rurpy@yahoo.com - 2013-06-25 15:37 -0700
  Re: newbie EOL while scanning string literal rurpy@yahoo.com - 2013-06-25 16:44 -0700
    Re: newbie EOL while scanning string literal willlewis965@gmail.com - 2013-06-25 17:05 -0700
      Re: newbie EOL while scanning string literal rusi <rustompmody@gmail.com> - 2013-06-25 20:38 -0700
      Re: newbie EOL while scanning string literal Larry Hudson <orgnut@yahoo.com> - 2013-06-25 21:47 -0700
      Re: newbie EOL while scanning string literal Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-06-26 08:31 +0000

csiph-web