Problem1591--小志的理论

1591: 小志的理论

[Creator : ]
Time Limit : 1.000 sec  Memory Limit : 128 MiB

Description

小志在翻书的时候看到了Georg Cantor(Georg Cantor是现代数学的著名证明之一),Georg Cantor证明了有理数是可枚举的。Georg Cantor证明的表如下图所示:
1/1 , 1/2 , 1/3 , 1/4 , 1/5 , …

2/1 , 2/2 , 2/3 , 2/4 , …

3/1 , 3/2 , 3/3 , …

4/1 , 4/2 , …

5/1 , …



小志突发奇想,想用 Z 字形给上表的每一项编号。例如,第1项是 1/1, 第2项1/2,第3项2/1,第4项3/1,第5项2/2……等等,以此类推。

Input

整数N(1≤N≤10^7 )。

Output

表中的第N项。

Sample Input Copy

7

Sample Output Copy

1/4

Source/Category

admin