code used in blogposts