On 2014-06-19 17:21, Peter Pearson wrote:
On Thu, 19 Jun 2014 12:25:23 +0100, MRAB <pyt...@mrabarnett.plus.com> wrote: [snip]and then you can say:def myCase(c): if len(c) < 8 or len(c) > 80: return False if c in mySet: return False return True which can be shortened to: def myCase(c): return 8 <= len(c) <= 80 and c in mySetDon't you mean . . . return 8 <= len(c) <= 80 and c not in mySet ?
Yes, you're right. -- https://mail.python.org/mailman/listinfo/python-list