あってるかな?
x = 10 => 4
x = 50 => 37
x = 100 => 159
x = 150 => 451
x = 500 => 19162