From: Simon Wright <simon@pogner.demon.co.uk>
Subject: Re: Type problem, any suggestion?
Date: 1999/09/22
Date: 1999-09-22T00:00:00+00:00 [thread overview]
Message-ID: <x7vpuzaaez6.fsf@pogner.moho> (raw)
In-Reply-To: 37E8C094.36631D5F@lcc.uma.es
=?iso-8859-1?Q?Jos=E9=20Mar=EDa=20=C1lvarez?= Palomo <alvarezp@lcc.uma.es> writes:
> This exercise had to implement a generic ADT (for example a stack) and
> to implement a procedure library to widen the ADT functinality (for
> example, a procedure to know the length of a stack).
> I think your solution it is a very smart way to do it, but I am afraid
> it will be difficult to make students understand it.
Yes, I see what you mean!
If you aren't too concerned with the details (I suppose this depends
on whether you want the students to come up with a solution on their
own!), you might say something like
there is a package gen_dat which we can instantiate for any type
(eg, integer, float, you-name-it)
there is an extension of gen_dat called dat_lib (BTW, these names
seem a little vague to me!)
if you're going to make a new dat_lib you have to refer to a proper
instantiation of gen_dat (one that uses the appropriate type)
and you need to mention the type as well in the instantiation of
dat_lib to round things off
(I think the last point could be better expressed)
prev parent reply other threads:[~1999-09-22 0:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <37E2764A.2B0AA8C7@lcc.uma.es>
[not found] ` <x7vhfksofsb.fsf@pogner.moho>
1999-09-22 0:00 ` Type problem, any suggestion? José María Álvarez Palomo
1999-09-22 0:00 ` Simon Wright [this message]
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox