Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #107919 > unrolled thread
| Started by | Christopher Reimer <christopher_reimer@icloud.com> |
|---|---|
| First post | 2016-04-30 10:36 -0700 |
| Last post | 2016-04-30 10:36 -0700 |
| Articles | 1 — 1 participant |
Back to article view | Back to comp.lang.python
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: Not x.islower() has different output than x.isupper() in list output... Christopher Reimer <christopher_reimer@icloud.com> - 2016-04-30 10:36 -0700
| From | Christopher Reimer <christopher_reimer@icloud.com> |
|---|---|
| Date | 2016-04-30 10:36 -0700 |
| Subject | Re: Not x.islower() has different output than x.isupper() in list output... |
| Message-ID | <mailman.266.1462037788.32212.python-list@python.org> |
On 4/30/2016 10:11 AM, Stephen Hansen wrote: > You're thinking of the whole "string", but you're operating on > single-character substrings, and when " ".islower() is run, its false. > Because the two-pronged test, a) if all cased characters are lowercase > and b) there is at least one cased character. b) is failing. Ergo, > you're getting the underscores. I see where the problem lies in my thinking. I went looking for a single line solution for the whole string. If I had constructed a for loop and tried to reduce it to a single line, I *may* have understood the relationship between the different parts. Or maybe not. Blaming the documentation is a lot easier. ;) Thank you, Chris R.
Back to top | Article view | comp.lang.python
csiph-web