source code for lottery