Having Fun with Code Snippets March 2, 2006 here are some pieces of code that you write over and over again. Some of these pieces make sense as standard components or standard methods, such as logging or validation.