New submission from Jesse Silverman <jessevsilver...@gmail.com>:

The Python tutorial was not my first introduction to Python, but I see things 
in sections 4.2 and 4.7 that likely would have confused me a lot if it was.

In 4.2 near the end, we have great advice about how to avoid problems with 
modifying a collection while iterating thru it.

Unfortunately, it both makes use of a dict despite not having introduced it 
before at all within the tutorial (I wasn't shocked because it was NOT my first 
introduction to Python) and in fact, the .items() method which is beautifully 
explained in section 5.6, which hasn't been read yet.

I got thru it a bit shakily, and in a reference, rather than an introductory 
tutorial, it is quite literally impossible to present everything in a strict 
sequence, but I would definitely have been thrown for a loop if it was actually 
my first introduction to Python.

All was good again until I got to section 4.7.2, where I was again glad I had 
previously consumed tutorial materials concerning dict.  There is a forward 
reference to:
https://docs.python.org/3.9/library/stdtypes.html#typesmapping

Which every Python programmer should undoubtedly be familiar with eventually, 
but "why not?" to the more novice-friendly:
https://docs.python.org/3.9/tutorial/datastructures.html#dictionaries

The forward reference from this section to tuples in section 5 of the tutorial 
suggests that this might have been appropriate as well.

The dict, the tuple and parameter passing are all very basic topics indeed, but 
I would have found 4.7 very rough going if I had no prior exposure to dict and 
tuple.

This isn't a complaint demanding a refund for the cost of the tutorial, so much 
as an indication of where I think true novices attempting to follow the 
tutorial in sequence would likely be thrown for a loop.  I understand there is 
a healthy ecosystem of free and paid introductory tutorial material for Python, 
as evidenced by the fact that I was only working thru the tutorial just now, 
having been referred to it as a pre-req for other material I will be moving on 
to soon.

----------
assignee: docs@python
components: Documentation
messages: 385870
nosy: docs@python, jessevsilverman
priority: normal
severity: normal
status: open
title: Use of dicts in sections 4.2 and 4.7 of Python tutorial a bit confusing
versions: Python 3.9

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue43056>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to