Checking homogeneity of Array using List in Python

Joel Goldstick joel.goldstick at gmail.com
Sun Aug 25 11:54:25 EDT 2013


On Sun, Aug 25, 2013 at 2:03 AM, Chris Angelico <rosuav at gmail.com> wrote:
> On Sun, Aug 25, 2013 at 3:50 PM,  <sahil301290 at gmail.com> wrote:
>> NOTE: NO INBUILT FUNCTION BE USED. Thank you in advance.

You don't make it easy to help you with your homework by leaving out
information about what you have learned so far, and perhaps what you
have tried that doesn't work

Here are some hints:  Do you know what the any and all functions do in
python?  Do you know about list comprehensions or how to write a for
loop that iterates over all of the values in a list?

If you know about that stuff, think how  those skills could be used to
solve your problem.

This problem is so completely contrived that without knowing the
course of your study (what you have learned about python programming
so far) it is really useless to try to guess an acceptable answer.
Let me suggest you discuss this with your classmates if possible.


-- 
Joel Goldstick
http://joelgoldstick.com



More information about the Python-list mailing list