Partition following list of numbers by their remainder when divided by “3”-{Var numbers() = {5, 4, 1, 3, 9, 8, 6, 7, 2, 0}}

Partition following list of numbers by their remainder when divided by “3”-{Var numbers() = {5, 4, 1, 3, 9, 8, 6, 7, 2, 0}}

(Vb)
Public Sub PartitioningExample()
Dim numbers() = {5, 4, 1, 3, 9, 8, 6, 7, 2, 0}

Dim numberGroups = From n In numbers Group n By key = n Mod 3 Into Group _
Select Remainder = key, NumberGroup = Group

For Each g In numberGroups
Console.WriteLine("Numbers with a remainder of {0} when divided by 3:", g.Remainder)
For Each n In g.NumberGroup
Console.WriteLine(n)
Next
Next
End Sub
Can you Concat two arrays to create one sequence that contains each array's values, one after the other?
Can you Concat two arrays to create one sequence that contains each array's values, one after the other?
Write small Program to generate Xml Document from table like (StudentRecord Table) using linq query
Write small Program to generate Xml Document from table like (StudentRecord Table) using linq query.....
What is Quantifiers in reference linq to Dataset?
Quantifier Operators return the Boolean value (either True or false) if some or all the elements in a sequence satisfy a condition.
Post your comment