Competing tasks as an index of intelligence