rders.OrderBy(order =&gt; order.Cost).ThenBy(order =&gt; order.CustomerId);
</code></pre>
<p>Note: Result will be an <code>IOrderedEnumerable&lt;TElement&gt;</code>.</p>
<h2 id="join">Join</h2>
<pre><code class="language-csharp">var joined = customers.Join(orders, 
                            customer =&gt; customer.Id, 
                            order =&gt; order.CustomerId
                            (customer, order) =&gt; new
                            {
                                CustomerId = c