Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- fun add(n) x = x + n;
- fun del(n) x = x - n;
- fun mlt(n) x = x * n;
- fun manipulate_one(k,[],action) = []
- | manipulate_one(1,l1,action) = (action (hd l1)) :: tl l1
- | manipulate_one(k,l1,action) =
- if k >= 1 then
- hd l1 :: manipulate_one(k-1, tl l1, action)
- else
- l1;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement