title: Return object from array with highest value
body: <p>I want to return an object from an array who's property has the highest value. Currently I am doing the following</p>
  
  <pre><code>Get-VM | Sort-Object -Property ProvisionedSpaceGB | Select-Object -Last 1
  </code></pre>
  
  <p>This works but is inefficient. I don't need the entire array sorted, I just need the object with largest value. Ideally I would use something like</p>
  
  <pre><code>Get-VM | Measure-Object -Property ProvisionedSpaceGB -Maximum
  </code></pre>
  
  <p>but this only returns the value of the object property, not the entire object. Is there a way to have measure-object return the base object?</p>