A practical algorithm was obtained for directly generating an optimal guessing sequence for guessing under lies. An optimal guessing strategy was defined as one which minimizes the number of average number of guesses in determining the correct value of a random variable. The information-theoretic bounds on the average number of guesses for optimal strategies were also derived