summaryrefslogtreecommitdiffstats
path: root/Doc/faq
diff options
context:
space:
mode:
authorInada Naoki <songofacandy@gmail.com>2023-06-04 16:45:00 (GMT)
committerGitHub <noreply@github.com>2023-06-04 16:45:00 (GMT)
commit1237fb6a4b177ce8f750949b9006c58f9f22942e (patch)
treea44861634d5fb68afe8f71a9b8601a8837c0a1cb /Doc/faq
parent5a5ed7a3e616a372f054a1dd2e9a31ba32a87a67 (diff)
downloadcpython-1237fb6a4b177ce8f750949b9006c58f9f22942e.zip
cpython-1237fb6a4b177ce8f750949b9006c58f9f22942e.tar.gz
cpython-1237fb6a4b177ce8f750949b9006c58f9f22942e.tar.bz2
gh-80480: array: Add 'w' typecode. (#105242)
Diffstat (limited to 'Doc/faq')
-rw-r--r--Doc/faq/programming.rst6
1 files changed, 3 insertions, 3 deletions
diff --git a/Doc/faq/programming.rst b/Doc/faq/programming.rst
index ab5618d..6e18125 100644
--- a/Doc/faq/programming.rst
+++ b/Doc/faq/programming.rst
@@ -924,12 +924,12 @@ module::
'Hello, there!'
>>> import array
- >>> a = array.array('u', s)
+ >>> a = array.array('w', s)
>>> print(a)
- array('u', 'Hello, world')
+ array('w', 'Hello, world')
>>> a[0] = 'y'
>>> print(a)
- array('u', 'yello, world')
+ array('w', 'yello, world')
>>> a.tounicode()
'yello, world'