Mutable List Assignment

From CSE425S Wiki
Jump to navigation Jump to search

Code to Implement

create_mutable_list_from_immutable_list

fun create_mutable_list_from_immutable_list(xs) : 'a mutable_list = 
   raise NotYetImplemented

create_empty_mutable_list

fun create_empty_mutable_list() : 'a mutable_list = 
   raise NotYetImplemented

create_mutable_list_from_other_mutable_list

fun create_mutable_list_from_other_mutable_list(ml) : 'a mutable_list = 
   raise NotYetImplemented

to_immutable

fun to_immutable(ml : 'a mutable_list) : 'a list =
   raise NotYetImplemented

length

fun length(ml : 'a mutable_list) : int =
   raise NotYetImplemented

insert_at_front

fun insert_at_front(ml : 'a mutable_list, item : 'a) : unit =
   raise NotYetImplemented

insert_at_back

fun insert_at_back(ml : 'a mutable_list, item : 'a) : unit =
   raise NotYetImplemented

remove_first_match

fun remove_first_match(ml : ''a mutable_list, item : ''a) : bool =
    raise NotYetImplemented

concat

fun concat(a : 'a mutable_list, b : 'a mutable_list) : unit = 
   raise NotYetImplemented

reverse

fun reverse(ml : 'a mutable_list) : unit =
   raise NotYetImplemented