My Data Table(DeviceInfo):
ID | OS | Device ----------------------------------------------- 1 | Android 2.2 | Samsung 2 | Linux/Android 4.2 | LG 3 | Linux/Android 4.4.2 | HTC 4 | Android 3.2 | Samsung 5 | Android 3.0 | Motorola 6 | iOS 7.1.2 | iPad 7 | iOS 8.0 | iPhone 6 8 | iOS 6.1.6 | iPhone 4
I want to group this table by Android and ios user using Linq.Actually I have to group the table using the substring "Android" and "iOS".
My Output should be
ID | User | Count ---------------------------- 1 | Android | 5 2 | iOS | 3
How would I be able to get this table using linq?