Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- val preteji_1 = implode o rev o explode;
- val teksts = "roberts";
- val preteji = preteji_1 teksts;
- - use "md_var_1.sml";
- [opening md_var_1.sml]
- val fun_preteji = fn : string -> string
- val teksts = "roberts" : string
- val preteji = "strebor" : string
- val it = () : unit
- fun preteji_2(ievads,izvads) = if null(ievads) then izvads
- else preteji_2(tl(ievads), hd(ievads)::izvads);
- - use "md_var_2.sml";
- [opening md_var_2.sml]
- val preteji = fn : 'a list * 'a list -> 'a list
- val it = () : unit
- - preteji([1,2,3,4,5,10],[]);
- val it = [10,5,4,3,2,1] : int list
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement