Advertisements
I have a long string name. Example: "Ahmet Enes Söylemez"
. I want to get only "AE"
letters from this array. How can I do it ?
@{ string result = string.Concat(kullanici.AdSoyad.Where(char.IsUpper));
@result
}
>Solution :
You’re almost there: Just .Take(2)
string result = string.Concat(kullanici.AdSoyad.Where(char.IsUpper).Take(2));