Likewise, the expected percentage of people using the education discount is part of Apple's calculation. Even if they lose money on the device (which I personally think is unlikely), they'll make it back from subscriptions and their cut of app store purchases.
The expected percentage of people using a coupon is often part of the calculation (however vague) when deciding the coupon.