Some random pieces of code