Improvement to Cookie Algorithm!