
31.12.19 08:20, iman.h.a.khamse@gmail.com пише:
Hi I think the following syntax's:
if foo in foobar or bar in foobar or baz in foobar: pass if foo in foobar and bar in foobar and baz in foobar: pass
can be more readable and shorter if written as:
if foo or bar or baz in foobar: pass if foo and bar and baz in foobar: pass
maybe for "is" instead of:
if foobar is foo or foobar is bar or foobar is baz: pass
if foobar is foo or bar or baz: pass
This looks like an interesting idea for a completely new programming language (together with "when" proposed as an alias of "if" in the neighbor thread). Unfortunately it is not compatible with existing Python syntax. And be aware that despite such syntax looks more readable to you, it may look confusing and ambiguous to other programmers.