Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- red
- red
- Grey
- Grey
- red
- blue
- blue
- Green
- White
- Grey
- red Count=2 index=0 (contain the duplicate cluster start index)
- Grey Count=2 index=2
- red Count=1 index=4
- blue Count=2 index=5
- Green Count=1 index=6
- White Count=1 index=7
- Grey Count=1 index=8
- var result = from p in a //a is the list
- group p by p into g
- select new { value=g.Key,count=g.Count()};
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement