revised Grandma code