Here we show you use Go
to write this topic:
package main
import "fmt"
func main() {
a := 1.0
k := 0.0
i := 2.0
fmt.Scan(&k)
for ; a < k; i++{
a += 1.0/i
}
fmt.Print(i-1)
}
There is a small detail, at the last judgment, when, i
at the end of the last cycle added an extra 1, so when output i
to-1