Yeah... but as already discussed, the part that converts those strings into actual arrays should probably be separated from the other part. But hey - if they must be integral, then here:
# first arg: n
# second arg: array(ref) of strings which are comma-separated lists.
# return: list of nth elements.
sub nth_elemS
{
map { (split ',')[$_[0]] } @{$_[1]}
}