fortune's algo