The Ideal Mechanical Advantage for a lever is: IMA = rE/rL, where rE is the distance from the fulcrum to the effort force, and rL
This applies to all 3 classes of levers.
Levers can have less than 100% efficiency (or less than the IMA) for several reasons:

In this picture, L is the length of the beam, LL is the length of the beam that is on the load side of the fulcrum, and Le is the length of the beam on the effort side of the fulcrum. If M is the mass of the beam itself, then the IMA is given by: