My solution for the lcd quiz