pub fn level(spent: f64, cap: f64) -> u8
How far spent is into cap, as the alert level it has passed: 0, 50, 80 or 100.
spent
cap