Which element is at its final position after the partitioning step in Quicksort? In Algorithms, 4th Edition, I read that after the partitioning step one element is in its final position.


  The entry a[j] is in its final place in the array, for some j.
  
  No entry in a[lo] through a[j-1] is greater than a[j].
  
  No entry in a[j+1] through a[hi] is less than a[j].


And this comes from Algorithms, 4th Edition, as well:


  First, we arbitrarily choose a[lo] to be the partitioning item—the one
  that will go into its final position.


Does the pivot go into its final position for all inputs without exception?
The details depend on the partitioning method used, but usually the pivot ends up in its final position.

That follows from the second and third statement, by the way: all elements smaller than the pivot are to the left of it, and the larger to the right. The pivot is in between, and that is clearly its final position in the sorted array.

That the second and third statement hold is the central property of the partitioning method used.