newbie's question

Michael Rueger michael at
Thu May 13 09:43:08 UTC 2004

Jenny wrote:

> I wrote a method as follows.
> initialize: xAxis values: yAxis
> "construct a polygonal membership function"

> When I execute this method by the commands, It tell me "MfLinear 
> class(Object)>>doesNotUnderstand: #initialize:values:"
> v1_#(1 3 5 5 9)
> v2_#(0 1 1 0 1)
> mm_MfLinear
> mm initialize: v1 values: v2

You fell into a typical newbie trap ;-)

When you take a closer look at the error message,
it says "MfLinear class". And looking at your code, you will see that 
indeed you sent the message to the class MfLinear, and not to an 
instance of that class.
So your code should look like this:

mm := MfLinear new.
mm initialize: v1 values: v2



More information about the Squeak-dev mailing list