Utility function for logging, cleans examples up