Practice question

Rustom Mody rustompmody at
Mon Oct 6 04:47:04 CEST 2014

On Monday, October 6, 2014 5:04:11 AM UTC+5:30, Skip Montanaro wrote:
> On Oct 5, 2014 6:07 PM, Seymore4Head wrote:
> > For the record, I don't want a hint.  I want the answer.
> > I see a practice question is similar to this.
> > 15 <= x < 30  And it wants a similar expression that is equivalent.
> Maybe
>     30 > x >= 15
> ? Seems more "similar" to the original expression than the other possibilities.

> As to how to try it out, bring up the Python prompt, assign various
> values to x, and keep evaluating the possibilities. To simplify
> evaluation off a bunch of alternatives, consider defining a function
> which takes x add a parameter and print out the various expression
> values. I'd give a concrete example, but don't has a prompt
> available on my phone...

An interesting data-point.
We have a here a poster who's asked some 20 or so python questions
and still seems not to know how to use the interpreter interactively.

Sorry Seymore if this sounds condescending -- its not a complaint
against you but against those who treat the print statement/expression as
kosher for newbies. Imagine someone who has driven a car for a month but has
no clue about the basic rule of keep-left (or right).

More information about the Python-list mailing list