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


Groups > comp.lang.python > #37916

Re: Please provide a better explanation of tuples and dictionaries

Path csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!gegeweb.org!newsfeed.kamp.net!newsfeed.kamp.net!newsfeed.freenet.ag!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <msirenef@lightbird.net>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.009
X-Spam-Evidence '*H*': 0.98; '*S*': 0.00; 'python': 0.09; 'compact': 0.09; 'explanation': 0.09; 'python:': 0.09; 'tuple': 0.09; 'advance': 0.10; 'finished': 0.15; 'dictionaries': 0.16; 'jr.': 0.16; "o'reilly": 0.16; 'purposes.': 0.16; 'received:74.55.86': 0.16; 'received:74.55.86.74': 0.16; 'received:smtp.webfaction.com': 0.16; 'received:webfaction.com': 0.16; 'subject:dictionaries': 0.16; 'wrote:': 0.17; 'examples': 0.18; 'code.': 0.20; 'all,': 0.21; 'tuples': 0.22; 'example': 0.23; 'programming': 0.23; 'testing': 0.24; 'header:In-Reply- To:1': 0.25; 'header:User-Agent:1': 0.26; "doesn't": 0.28; 'actual': 0.28; 'ansi': 0.29; 'clever': 0.29; 'comparison': 0.29; 'python"': 0.29; 'daniel': 0.30; 'initially': 0.30; 'code': 0.31; '(and': 0.32; 'automation': 0.33; 'anyone': 0.33; 'to:addr:python- list': 0.33; 'point.': 0.33; 'tutorial': 0.33; 'or,': 0.34; 'thanks': 0.34; 'pm,': 0.35; 'but': 0.36; 'subject:Please': 0.36; 'test': 0.36; 'level': 0.37; 'being': 0.37; 'subject:: ': 0.38; 'mark': 0.38; 'some': 0.38; 'to:addr:python.org': 0.39; 'received:192': 0.39; 'application': 0.40; 'received:192.168': 0.40; 'provide': 0.62; 'more': 0.63; 'explanations': 0.65; 'mother': 0.65; 'real-world': 0.65; 'published': 0.71; 'replies.': 0.84; 'subject:better': 0.84; 'subject:provide': 0.84; 'numerous': 0.91
Date Tue, 29 Jan 2013 22:51:40 -0500
From Mitya Sirenef <msirenef@lightbird.net>
User-Agent Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130106 Thunderbird/17.0.2
MIME-Version 1.0
To python-list@python.org
Subject Re: Please provide a better explanation of tuples and dictionaries
References <hKCdnWgrOqkwFpXMnZ2dnUVZ_qadnZ2d@o1.com>
In-Reply-To <hKCdnWgrOqkwFpXMnZ2dnUVZ_qadnZ2d@o1.com>
Content-Type text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding 7bit
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.1199.1359517908.2939.python-list@python.org> (permalink)
Lines 39
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1359517908 news.xs4all.nl 6979 [2001:888:2000:d::a6]:34146
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:37916

Show key headers only | View raw


On 01/29/2013 09:55 PM, Daniel W. Rouse Jr. wrote:
> Hi all,
 >
 > I have recently started learning Python (2.7.3) but need a better 
explanation of how to use tuples and dictionaries.
 >
 > I am currently using "Learning Python" by Mark Lutz and David Ascher, 
published by O'Reilly (ISBN 1-56592-464-9)--but I find the explanations 
insufficient and the number of examples to be sparse. I do understand 
some ANSI C programming in addition to Python (and the book often 
wanders off into a comparison of C and Python in its numerous 
footnotes), but I need a better real-world example of how tuples and 
dictionaries are being used in actual Python code.
 >
 > Any recommendations of a better book that doesn't try to write such 
compact and clever code for a learning book? Or, can an anyone provide 
an example of more than a three-line example of a tuple or dictionary?
 >
 > The purpose of my learning Python in this case is not for enterprise 
level or web-based application level testing at this point. I initially 
intend to use it for Software QA Test Automation purposes.
 >
 > Thanks in advance for any replies.


It's not finished yet, but you may find my text-movie tutorial on
dicts useful:

http://lightbird.net/larks/tmovies/dicts.html

  -m



-- 
Lark's Tongue Guide to Python: http://lightbird.net/larks/

Idleness is the mother of psychology.  Friedrich Nietzsche

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


Thread

Please provide a better explanation of tuples and dictionaries "Daniel W. Rouse Jr." <dwrousejr@nethere.comNOSPAM> - 2013-01-29 18:55 -0800
  Re: Please provide a better explanation of tuples and dictionaries Chris Angelico <rosuav@gmail.com> - 2013-01-30 14:11 +1100
    Re: Please provide a better explanation of tuples and dictionaries "Daniel W. Rouse Jr." <dwrousejr@nethere.comNOSPAM> - 2013-01-29 19:42 -0800
      Re: Please provide a better explanation of tuples and dictionaries Chris Angelico <rosuav@gmail.com> - 2013-01-30 14:51 +1100
  Re: Please provide a better explanation of tuples and dictionaries Mitya Sirenef <msirenef@lightbird.net> - 2013-01-29 22:51 -0500
  Re: Please provide a better explanation of tuples and dictionaries John Gordon <gordon@panix.com> - 2013-01-30 05:15 +0000
    Re: Please provide a better explanation of tuples and dictionaries "Daniel W. Rouse Jr." <dwrousejr@nethere.comNOSPAM> - 2013-01-29 22:14 -0800
      Re: Please provide a better explanation of tuples and dictionaries Chris Angelico <rosuav@gmail.com> - 2013-01-30 17:25 +1100
      Re: Please provide a better explanation of tuples and dictionaries Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-01-30 07:12 +0000
  Re: Please provide a better explanation of tuples and dictionaries rusi <rustompmody@gmail.com> - 2013-01-30 00:14 -0800
  Re: Please provide a better explanation of tuples and dictionaries Rick Johnson <rantingrickjohnson@gmail.com> - 2013-02-02 21:20 -0800
    Re: Please provide a better explanation of tuples and dictionaries Michael Torrie <torriem@gmail.com> - 2013-02-03 00:14 -0700
    Re: Please provide a better explanation of tuples and dictionaries Chris Angelico <rosuav@gmail.com> - 2013-02-03 18:21 +1100

csiph-web