fun main() { var wants = readln().toInt() var count = 0 while (true) { if (wants < 100) break wants -= 500 count++ } println(count) }