| Modelling Systems
Additional Exercises on Sequences |
NumOfOccurr: ? -> ?
that returns the number of occurrences of character x in sequence p of type Line.
NumOfDistinctEls: ? -> ?
that returns the number of distinct elements in p of type Line.
Distance: ? * ?
which, given p and q of type Line, returns the number of distinct characters that are either in p or in q but not in both.
| John.Fitzgerald@ncl.ac.uk | 6 June 1999 ... |