Angular Array Get Last Element Of String In C