code developement. unfinished function