filled functions with code