Problems In Discrete Probability Theory And Cryptography