On the planet Mars a year lasts exactly *n* days (there are no leap years on Mars). But Martians have the same weeks as earthlings — 5 work days and then 2 days off. Your task is to determine the minimum possible and the maximum possible number of days off per year on Mars.
The first line of the input contains a positive integer *n* (1 ≤ *n* ≤ 1 000 000) — the number of days in a year on Mars.
In the first sample there are 14 days in a year on Mars, and therefore independently of the day a year starts with there will be exactly 4 days off .

In the second sample there are only 2 days in a year on Mars, and they can both be either work days or days off.
14
4 4
2
0 2
1
0 1
3
0 2
4
0 2
5
0 2
6
1 2
7
2 2
8
2 3
9
2 4
10
2 4
11
2 4
12
2 4
13
3 4
1000000
285714 285715
16
4 6
17
4 6
18
4 6
19
4 6
20
5 6
21
6 6
22
6 7
23
6 8
24
6 8
25
6 8
26
6 8
27
7 8
28
8 8
29
8 9
30
8 10
100
28 30
99
28 29
98
28 28
97
27 28
96
26 28
95
26 28
94
26 28
93
26 28
92
26 27
91
26 26
90
25 26
89
24 26
88
24 26
87
24 26
86
24 26
85
24 25
84
24 24
83
23 24
82
22 24
81
22 24
80
22 24
1000
285 286
999
284 286
998
284 286
997
284 286
996
284 286
995
284 285
994
284 284
993
283 284
992
282 284
991
282 284
990
282 284
989
282 284
988
282 283
987
282 282
986
281 282
985
280 282
984
280 282
983
280 282
982
280 282
981
280 281
980
280 280
10000
2856 2858
9999
2856 2858
9998
2856 2858
9997
2856 2857
9996
2856 2856
9995
2855 2856
9994
2854 2856
9993
2854 2856
9992
2854 2856
9991
2854 2856
9990
2854 2855
9989
2854 2854
9988
2853 2854
9987
2852 2854
9986
2852 2854
9985
2852 2854
9984
2852 2854
9983
2852 2853
9982
2852 2852
9981
2851 2852
9980
2850 2852
100000
28570 28572
99999
28570 28572
99998
28570 28572
99997
28570 28572
99996
28570 28571
99995
28570 28570
99994
28569 28570
99993
28568 28570
99992
28568 28570
99991
28568 28570
99990
28568 28570
99989
28568 28569
99988
28568 28568
99987
28567 28568
99986
28566 28568
99985
28566 28568
99984
28566 28568
99983
28566 28568
99982
28566 28567
99981
28566 28566
99980
28565 28566
999999
285714 285714
999998
285713 285714
999997
285712 285714
999996
285712 285714
999995
285712 285714
999994
285712 285714
999993
285712 285713
999992
285712 285712
999991
285711 285712
999990
285710 285712
999989
285710 285712
999988
285710 285712
999987
285710 285712
999986
285710 285711
999985
285710 285710
999984
285709 285710
999983
285708 285710
999982
285708 285710
999981
285708 285710
999980
285708 285710
234123
66892 66893
234122
66892 66892
234121
66891 66892
234120
66890 66892
234119
66890 66892
234118
66890 66892
234117
66890 66892
234116
66890 66891
234115
66890 66890
234114
66889 66890
234113
66888 66890
234112
66888 66890
234111
66888 66890
234110
66888 66890
234109
66888 66889
234108
66888 66888
234107
66887 66888
234106
66886 66888
234105
66886 66888
234104
66886 66888
234103
66886 66888
868531
248151 248152
868530
248150 248152
868529
248150 248152
868528
248150 248152
868527
248150 248152
868526
248150 248151
868525
248150 248150
868524
248149 248150
868523
248148 248150
868522
248148 248150
868521
248148 248150
868520
248148 248150
868519
248148 248149
868518
248148 248148
868517
248147 248148
868516
248146 248148
868515
248146 248148
868514
248146 248148
868513
248146 248148
868512
248146 248147
868511
248146 248146
123413
35260 35262
123412
35260 35262
123411
35260 35261
123410
35260 35260
123409
35259 35260
123408
35258 35260
123407
35258 35260
123406
35258 35260
123405
35258 35260
123404
35258 35259
123403
35258 35258
123402
35257 35258
123401
35256 35258
123400
35256 35258
123399
35256 35258
123398
35256 35258
123397
35256 35257
123396
35256 35256
123395
35255 35256
123394
35254 35256
123393
35254 35256
15
4 5
n = int(input())
maxi = 0
mini = 0

if n <= 7:
    print(0,2)

else:
    count = 0
    while n > 0:
        if n >= 7:
            n -= 7
            mini += 2
            maxi = mini
        else:
            if n > 2:
                maxi = mini + 2
                break
            else:
                maxi = mini + n
                break


    print(mini,maxi)
