diy function + comments
more comments.