[EMAIL PROTECTED] a écrit :
Bruno Desthuilliers:
What is data is another type of sequence or iterable ?-)<

The original problem statement was:

I did read it, thanks.


If the problem changes, then the code has to/can change. When you
write code it's better to avoid over-generalization

It's not a problem of "over-generalization", it's a problem of not being _uselessly_ restrictive. Your solution will fail with any non-list sequence, for no good reason.

> (this is also a
> rule in Agile programming practices).

The rational behind the YAGNI rule is to avoid wasting time on useless generalizations. This does not apply here since the more generic solution doesn't take more time to write or maintain.
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to