Rectangles 2

Time limit2sMemory limit512 MB

Summary
Count the number of unordered pairs (a, b) of positive integers with a <= b and a*b <= n.
Level

Medium4 of 10

Topics
Math, Number theory, Brute force
Solved
No attempts yet

Problem

Byteman has nn squares with side length 11 (unit squares). Using these squares, how many different rectangles can he build?

Two rectangles are considered different if neither of them can be turned into the other by rotation and translation. While building a rectangle, Byteman may not deform a square, and he may not place any square on top of another.

A rectangle whose sides are positive integers aa and bb is made of exactly a⋅ba \cdot b unit squares, so Byteman can build it only when a⋅b≤na \cdot b \le n. A rectangle and the same rectangle rotated by 90∘90^\circ (that is, a×ba \times b and b×ab \times a) count as one and the same.

Input

The first and only line of the standard input contains one integer nn (1≤n≤1 000 000 0001 \le n \le 1\,000\,000\,000).

Output

Print a single integer: the number of different rectangles Byteman can build using his squares.

Hint

Examples3

  1. Example 1

    Input
    6
    
    Expected output
    8
    
  2. Example 2

    Input
    1
    
    Expected output
    1
    
  3. Example 3

    Input
    4
    
    Expected output
    5