Add a Contains method to monkey list?

Monkey Forums/Monkey Programming/Add a Contains method to monkey list?

clevijoki(Posted 2011) [#1]
If this code could be added to list.monkey, it would be great. Unless there is an easier way to do this?

	Method Contains:Bool(value:T)
		Local node:=_head._succ
		While node<>_head
			Local succ:=node._succ
			If Equals( node._data,value ) Return
			node=succ
		Wend		
	End Method



therevills(Posted 2011) [#2]
Create your own list class and an the functions yourself... I did that and it works pretty well. Oh and you could also use Diddy's Arraylist class too ;)


marksibly(Posted 2011) [#3]
Hi,

> If this code could be added to list.monkey, it would be great.

Will do!