random bits of code for reference