Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #79194
| References | <CAGGBd_pBXYmoAQXBU2Tz4UGHRnHLA8BZJ36SsrK-6D2ifvD-5w@mail.gmail.com> <20141016004254.GA74782@cskk.homeip.net> |
|---|---|
| Date | 2014-10-15 19:31 -0600 |
| Subject | Re: Question About Running Python code |
| From | Ian Kelly <ian.g.kelly@gmail.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.14907.1413423103.18130.python-list@python.org> (permalink) |
[Multipart message — attachments visible in raw view] - view raw
On Oct 15, 2014 7:04 PM, "Cameron Simpson" <cs@zip.com.au> wrote: > > On 15Oct2014 16:09, Dan Stromberg <drsalists@gmail.com> wrote: >> >> On Wed, Oct 15, 2014 at 3:50 PM, ryguy7272 <ryanshuell@gmail.com> wrote: >>> >>> #1) That's very bizarre to mix single quotes and double quotes in a single language. Does Python actually mix single quotes and double quotes? >> >> >> I'm not sure what you mean by "mix". C uses single quotes and double >> quotes, right? > > > Yes, but it uses single quotes for characters (a single byte integer type) and double quotes for strings. Python doesn't really have a single character type, and lets the user use either quote mark as they see fit. Ryan finds this unfamiliar. In any case, it's hardly bizarre; it's common among interpreted languages. Other languages that allow both single- and double-quote strings include ECMAScript and Lua. Perl, PHP and Ruby also have both variants but distinguish between them for interpolation.
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Re: Question About Running Python code Ian Kelly <ian.g.kelly@gmail.com> - 2014-10-15 19:31 -0600
csiph-web