func readInt() -> Int {
    return Int(readLine()!)!
}

func mainC() {
    let N = readInt()

    for n in 1...N {
        var count = 0

        let maxI = 100
        for i in 1...maxI {
            let maxJ = min(max(n - (i + 2)*i, 1), 100)
            for j in 1...maxJ {
                let maxK = min(max(n - (i + 2)*i - (j + 2)*j, 1), 100)

                for k in 1...maxK {
                    if (n == ((i + j + k) * (i + j + k) - i*j - i*k - j*k)) {
                        count += 1
                    }
                }

            }
        }

        print(count)
    }

}

mainC()