$index++ until @repo[$index] eq $input or $i > $#repo; #### $index++ until $repo[$index] eq $input or $index > $#repo;