Given a closed subspace S of a Hilbert space H and a (bounded) selfadjoint operator B acting on H, a min-max representation of the shorted operator (or Schur complement) of B to S is obtained under compatibility hypotheses. Also, an extension of Pekarev's formula is given.