buggy example codes fixed

get_preallocated_path should take file_name to produce the desired output shown later and add_group takes file_path