[Tutor] question on Partition [off-topic rant/flame]

Danny Yoo dyoo@hkn.eecs.berkeley.edu
Wed Dec 11 15:47:01 2002


On Wed, 11 Dec 2002, sachin mehra wrote:

> So is there any other function which does it? Something like partition
> as you mentioned? I think there is some function in unix which does it
> ..Would you know ? Thanx,


Dear Sachin,

I can't think of a Unix utility that will do it directly; this is
something that's so specialized, so artificial, that you will probably
need to cook the function up in the language of your choice.


Forgive me for being cruel and blunt about this, but your question is not
difficult.  This kind of homework question is supposed to be covered by an
introductory CS course, and you can solve it using standard recursive
techniques.

If you weren't doing this for a class, I really wouldn't have any
reservations giving advice to a fellow student.  But you are doing this
for a class project, in what sounds like an advanced CS class, and your
responses are hinting that you haven't tried writing this function using
your own efforts.


I cannot write this program for you.