Select Case dr(a) Case is < 39 dr(b) = 0 Case 40 To 59 dr(b) = dr(a) * 0.05 Case 60 To 99 dr(b) = 3 + (dr(a) - 60) * 0.1 Case is > 99 dr(b) = 7 + (dr(a) - 100) * 0.2
End Select