Snuke has decided to play with a six-sided die. Each of its six sides shows an integer 1 through 6, and two numbers on opposite sides always add up to 7.
Snuke will first put the die on the table with an arbitrary side facing upward, then repeatedly perform the following operation:
 - Operation: Rotate the die 90° toward one of the following directions: left, right, front (the die will come closer) and back (the die will go farther). Then, obtain y points where y is the number written in the side facing upward.
For example, let us consider the situation where the side showing 1 faces upward, the near side shows 5 and the right side shows 4, as illustrated in the figure.
If the die is rotated toward the right as shown in the figure, the side showing 3 will face upward.
Besides, the side showing 4 will face upward if the die is rotated toward the left, the side showing 2 will face upward if the die is rotated toward the front, and the side showing 5 will face upward if the die is rotated toward the back.
Find the minimum number of operation Snuke needs to perform in order to score at least x points in total.

-----Constraints-----
 - 1 ≦ x ≦ 10^{15}
 - x is an integer.

-----Input-----
The input is given from Standard Input in the following format:
x

-----Output-----
Print the answer.

-----Sample Input-----
7

-----Sample Output-----
2

Difficulty: MEDIUM_HARD

Solutions:
x = int(input())
if x <= 6:
	print(1)
	return
elif 7 < x <= 11:
	print(2)
	return
else:
	n = x // 11
	if x - n * 11 == 0:
		print(2 * n)
		return
	elif x - n * 11 <= 6:
		print(2 * n + 1)
	else:
		print(2 * n + 2)


import bisect, copy, heapq, math, sys
from collections import *
from functools import lru_cache
from itertools import accumulate, combinations, permutations, product

def input():
	return sys.stdin.readline()[:-1]

def ruiseki(lst):
	return [0] + list(accumulate(lst))

def celi(a, b):
	return -(-a // b)
sys.setrecursionlimit(5000000)
mod = pow(10, 9) + 7
al = [chr(ord('a') + i) for i in range(26)]
direction = [[1, 0], [0, 1], [-1, 0], [0, -1]]
x = int(input())
if x % 11 == 0:
	print(x // 11 * 2)
else:
	print(x // 11 * 2 + x % 11 // 7 + 1)


x = int(input())
if x <= 11:
	if x <= 6:
		print(1)
	else:
		print(2)
else:
	ans = x // 11 * 2
	x = x % 11
	if x == 0:
		print(ans)
	elif x <= 6:
		print(ans + 1)
	else:
		print(ans + 2)


import sys
input = sys.stdin.readline
sys.setrecursionlimit(10 ** 7)
x = int(input())
ans = 0
q = x // 11
r = x % 11
ans += q * 2
if r == 0:
	pass
elif r <= 6:
	ans += 1
else:
	ans += 2
print(ans)


x = int(input())
if 7 <= x <= 11:
	print(2)
elif x <= 6:
	print(1)
else:
	(a, b) = divmod(x, 11)
	if b == 0:
		print(2 * a)
	elif b <= 6:
		print(2 * a + 1)
	else:
		print(2 * a + 2)


N = int(input())
ans = N // 11 * 2
nokori = N % 11
if nokori == 0:
	ans += 0
elif nokori <= 6:
	ans += 1
else:
	ans += 2
print(ans)


x = int(input())
rem = x % 11
cnt = (x - rem) // 11
cnt *= 2
if 0 < rem <= 6:
	cnt += 1
elif rem > 6:
	cnt += 2
print(cnt)


import sys
from collections import deque
from bisect import bisect_left, bisect_right, insort_left, insort_right
from heapq import heapify, heappop, heappush
from itertools import product, permutations, combinations, combinations_with_replacement
from functools import reduce
from math import sin, cos, tan, asin, acos, atan
sys.setrecursionlimit(10 ** 6)
INF = 10 ** 20
eps = 1e-20
MOD = 10 ** 9 + 7

def lcm(x, y):
	return x * y // gcd(x, y)

def lgcd(l):
	return reduce(gcd, l)

def llcm(l):
	return reduce(lcm, l)

def powmod(n, i, mod):
	return pow(n, mod - 1 + i, mod) if i < 0 else pow(n, i, mod)

def div2(x):
	return x.bit_length()

def div10(x):
	return len(str(x)) - (x == 0)

def perm(n, mod=None):
	ans = 1
	for i in range(1, n + 1):
		ans *= i
		if mod != None:
			ans %= mod
	return ans

def intput():
	return int(input())

def mint():
	return map(int, input().split())

def lint():
	return list(map(int, input().split()))

def ilint():
	return (int(input()), list(map(int, input().split())))

def judge(x, l=['Yes', 'No']):
	print(l[0] if x else l[1])

def lprint(l, sep='\n'):
	for x in l:
		print(x, end=sep)

def ston(c, c0='a'):
	return ord(c) - ord(c0)

def ntos(x, c0='a'):
	return chr(x + ord(c0))

class counter(dict):

	def __init__(self, *args):
		super().__init__(args)

	def add(self, x):
		self.setdefault(x, 0)
		self[x] += 1

class comb:

	def __init__(self, n, mod=None):
		self.l = [1]
		self.n = n
		self.mod = mod

	def get(self, k):
		(l, n, mod) = (self.l, self.n, self.mod)
		k = n - k if k > n // 2 else k
		while len(l) <= k:
			i = len(l)
			l.append(l[i - 1] * (n + 1 - i) // i if mod == None else l[i - 1] * (n + 1 - i) * powmod(i, -1, mod) % mod)
		return l[k]
x = intput()
print(2 * (x // 11) + (x % 11 != 0) + (x % 11 > 6))


def main():
	n = int(input())
	ans = 0
	ans += n // 11 * 2
	if n % 11 <= 6 and n % 11 != 0:
		ans += 1
	elif n % 11 <= 10 and n % 11 > 6:
		ans += 2
	print(ans)
main()


n = int(input())
if n <= 6:
	print(1)
elif n % 11 == 0:
	print(2 * (n // 11))
elif n % 11 <= 6:
	print(2 * (n // 11) + 1)
else:
	print(2 * n // 11 + 1)


import sys
import bisect
input = sys.stdin.readline
x = int(input())
ans = 2 * (x // 11)
if 0 < x % 11 <= 6:
	ans += 1
elif x % 11 > 6:
	ans += 2
print(ans)


import sys
import math
import itertools
from collections import defaultdict, deque, Counter
from copy import deepcopy
from bisect import bisect, bisect_right, bisect_left
from heapq import heapify, heappop, heappush
input = sys.stdin.readline

def RD():
	return input().rstrip()

def F():
	return float(input().rstrip())

def I():
	return int(input().rstrip())

def MI():
	return map(int, input().split())

def MF():
	return map(float, input().split())

def LI():
	return list(map(int, input().split()))

def TI():
	return tuple(map(int, input().split()))

def LF():
	return list(map(float, input().split()))

def Init(H, W, num):
	return [[num for i in range(W)] for j in range(H)]

def main():
	N = I()
	ans = 2 * (N // 11)
	N -= ans // 2 * 11
	if N <= 6 and N > 0:
		ans += 1
	elif N >= 7:
		ans += 2
	print(ans)

def __starting_point():
	main()
__starting_point()


import sys
if sys.platform == 'ios':
	sys.stdin = open('input_file.txt')
x = int(input())
k = x // 11
if x == 11 * k:
	ans = 2 * k
elif 11 * k < x and x <= 11 * k + 6:
	ans = 2 * k + 1
else:
	ans = 2 * (k + 1)
print(ans)


import math
x = int(input())
if 1 <= x % 11 <= 6:
	print(math.ceil(x / 11) * 2 - 1)
else:
	print(math.ceil(x / 11) * 2)


x = int(input())
a = x // 11
a *= 2
b = x % 11
if b == 0:
	None
elif b <= 6:
	a += 1
else:
	a += 2
print(a)


import sys

def input():
	return sys.stdin.readline().strip()

def mapint():
	return map(int, input().split())
sys.setrecursionlimit(10 ** 9)
x = int(input())
cnt = -(-x // 11)
if cnt * 11 - x >= 5:
	print(cnt * 2 - 1)
else:
	print(cnt * 2)


x = int(input())
q = x // 11
ans = 2 * q
r = x % 11
if r > 6:
	ans += 2
if 0 < r <= 6:
	ans += 1
print(ans)


import sys
x = int(sys.stdin.readline())
n = x // 11
r = x % 11
if r == 0:
	print(2 * n)
elif r <= 6:
	print(2 * n + 1)
else:
	print(2 * (n + 1))


x = int(input())
ans = x // 11 * 2
print(ans + (x % 11 > 0) + (x % 11 > 6))


import sys
input = sys.stdin.readline
x = int(input())
ans = 0
m = x // 11
n = x % 11
if n == 0:
	ans = 2 * m
if 0 < n and n <= 6:
	ans = 2 * m + 1
if 6 < n:
	ans = 2 * m + 2
print(ans)


x = int(input())
ans = x // 11 * 2
if 0 < x % 11 < 7:
	ans += 1
elif x % 11 >= 7:
	ans += 2
print(ans)


import math
x = int(input())
xi = math.floor(x / 5.5)
for i in range(xi, 10000000000000000000000000000):
	if x <= 6 * i - math.floor(i / 2):
		xa = i
		break
print(xa)


x = int(input())
idx = x // 11
ans = idx * 2
if x % 11 != 0:
	ans += 2
if 0 < x % 11 and x % 11 <= 6:
	ans -= 1
print(ans)


x = int(input())
if x <= 11:
	if x <= 6:
		print(1)
	else:
		print(2)
else:
	rot = x // 11
	mod = x % 11
	if mod > 6:
		print(2 * rot + 2)
		return
	if mod > 0:
		print(2 * rot + 1)
		return
	print(2 * rot)


import os
import sys

def main():
	x = int(input())
	if x % 11 == 0:
		print(2 * (x // 11))
		return
	tmp = x // 11
	ans = tmp * 2
	new = x - tmp * 11
	if 0 < new <= 6:
		print(ans + 1)
	else:
		print(ans + 2)

def __starting_point():
	main()
__starting_point()


x = int(input())
c = (x + 10) // 11 * 2
if 11 * (c // 2) - 5 >= x:
	c -= 1
print(c)


x = int(input())
n = (x - 1) // 11
if n * 11 + 6 >= x:
	print(n * 2 + 1)
else:
	print(n * 2 + 2)


x = int(input())
p = (x + 11 - 1) // 11
q = (x + 11 - 1) % 11
if q < 6:
	ans = p * 2 - 1
else:
	ans = p * 2
print(ans)


N = int(input())

def solve(N):
	cnt = 0
	cnt += N // 11 * 2
	N %= 11
	if 0 < N <= 6:
		cnt += 1
	elif 6 < N < 11:
		cnt += 2
	return cnt
print(solve(N))


import sys

def I():
	return int(sys.stdin.readline().rstrip())
x = I() - 1
print(x // 11 * 2 + 1 + x % 11 // 6)


x = int(input())
a = x // 11
b = x % 11
if b == 0:
	ans = a * 2
elif b in range(1, 7):
	ans = a * 2 + 1
else:
	ans = a * 2 + 2
print(ans)


def main():
	N = int(input())
	ans = N // 11 * 2
	n = N % 11
	if n > 6:
		ans += 2
	elif n > 0:
		ans += 1
	print(ans)

def __starting_point():
	main()
__starting_point()


def main():
	x = int(input())
	div = x // 11
	rem = x % 11
	ans = div * 2 + (1 <= rem <= 10) + (7 <= rem <= 10)
	print(ans)

def __starting_point():
	main()
__starting_point()


def main():
	x = int(input())
	(ans, mod) = divmod(x, 11)
	ans *= 2
	if mod >= 7:
		ans += 2
	elif mod > 0:
		ans += 1
	print(ans)

def __starting_point():
	main()
__starting_point()


x = int(input())
n = x // 11
n = 2 * n
m = x % 11
if 1 <= m <= 6:
	n += 1
elif 7 <= m <= 10:
	n += 2
print(n)


N = int(input())
n = N % 11
K = N // 11 * 2
if n == 0:
	pass
elif 0 < n <= 6:
	K += 1
else:
	K += 2
print(K)


n = int(input())
ans = n // 11 * 2
if 0 < n % 11 <= 6:
	ans += 1
elif 6 < n % 11 <= 10:
	ans += 2
print(ans)


x = int(input())
(ans1, mod) = divmod(x, 11)
if mod == 0:
	print(ans1 * 2)
elif 1 <= mod <= 6:
	print(ans1 * 2 + 1)
else:
	print(ans1 * 2 + 2)


x = int(input())
if x <= 6:
	print(1)
elif x <= 11:
	print(2)
elif x % 11 == 0:
	print(2 * (x // 11))
elif x - x // 11 * 11 <= 6:
	print(2 * (x // 11) + 1)
elif x - x // 11 * 11 <= 11:
	print(2 * (x // 11) + 2)


x = int(input())
ans = x // 11 * 2
x = x % 11
if 1 <= x <= 6:
	ans += 1
if 7 <= x <= 11:
	ans += 2
print(ans)


def resolve():
	from math import ceil
	X = int(input())
	print(X // 11 * 2 + ceil(X % 11 / 6))
resolve()


x = int(input())
x_mod = x % 11
x_div = x // 11
if x % 11 == 0:
	print(x // 11 * 2)
elif x % 11 <= 6:
	print(x // 11 * 2 + 1)
else:
	print(x // 11 * 2 + 2)


x = int(input())
y = x % 11
if y > 0:
	cnt = 1
	if y > 6:
		cnt += 1
else:
	cnt = 0
print(x // 11 * 2 + cnt)


x = int(input())
if x <= 6:
	print(1)
elif x <= 11:
	print(2)
else:
	d = x // 11
	m = x % 11
	if m == 0:
		print(d * 2)
	elif m <= 6:
		print(d * 2 + 1)
	else:
		print(d * 2 + 2)


import sys
sys.setrecursionlimit(10 ** 9)
input = sys.stdin.readline

def int1(x):
	return int(x) - 1

def II():
	return int(input())

def MI():
	return list(map(int, input().split()))

def MI1():
	return list(map(int1, input().split()))

def LI():
	return list(map(int, input().split()))

def LI1():
	return list(map(int1, input().split()))

def LLI(rows_number):
	return [LI() for _ in range(rows_number)]

def MS():
	return input().split()

def LS():
	return list(input().strip('\n'))

def LLS(rows_number):
	return [LS() for _ in range(rows_number)]
INF = float('inf')
from math import ceil, floor, log2, log, sqrt
from itertools import combinations as comb, combinations_with_replacement as comb_w, accumulate, product, permutations
from collections import deque, defaultdict
from pprint import pprint

def solve():
	x = II()
	(p, q) = (x // 11, x % 11)
	p *= 2
	if q == 0:
		pass
	elif q <= 6:
		p += 1
	else:
		p += 2
	print(p)

def __starting_point():
	solve()
__starting_point()


X = int(input())
p = X // 11
q = (X % 11 + 6 - 1) // 6
print(p * 2 + q)


x = int(input())
rt = x // 11 * 2
tmp = x % 11
if tmp > 6:
	rt += 1
	tmp -= 6
print(rt + 1 if tmp > 0 else rt)


x = int(input())
ans = x // 11 * 2
rem = x % 11
if rem != 0 and rem < 7:
	ans += 1
elif rem != 0 and rem > 6:
	ans += 2
print(ans)


import bisect, collections, copy, itertools, math, string
import sys

def I():
	return int(sys.stdin.readline().rstrip())

def LI():
	return list(map(int, sys.stdin.readline().rstrip().split()))

def S():
	return sys.stdin.readline().rstrip()

def LS():
	return list(sys.stdin.readline().rstrip().split())

def main():
	x = I()
	ans = x // 11 * 2
	num = x % 11
	if num == 0:
		pass
	elif num <= 6:
		ans += 1
	else:
		ans += 2
	print(ans)
main()


x = int(input())
(d, m) = divmod(x, 11)
ans = d * 2
if 0 < m <= 6:
	ans += 1
elif m >= 7:
	ans += 2
print(ans)


x = int(input())
ans = x // 11 * 2
mod = x % 11
if mod == 0:
	pass
elif mod < 7:
	ans += 1
else:
	ans += 2
print(ans)


import decimal
x = decimal.Decimal(input())
n = x / decimal.Decimal(11)
ans = n * decimal.Decimal(2)
judge = int(ans)
if ans - judge < decimal.Decimal(0.1):
	print(int(ans))
else:
	print(int(ans) + 1)


import math
x = int(input())
if x % 11 == 0:
	ans = x // 11 * 2
else:
	ans = x // 11 * 2
	y = x % 11
	if y <= 6:
		ans += 1
	else:
		ans += 2
print(ans)


import math
y = int(input())
print((y * 10 - 9 + 54) // 55)


x = int(input())
cnt = 0
v = [0, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2]
print(2 * (x // 11) + v[x % 11])


import math
x = int(input())
t = math.ceil(x / 5.5)

def f(n):
	return 6 * n - n // 2
if x <= f(t - 1):
	print(t - 1)
elif x <= f(t):
	print(t)
else:
	print(t + 1)


x = int(input())
c = x // 11
m = x % 11
cnt = 2 * c
if 0 < m < 7:
	cnt += 1
elif 6 < m:
	cnt += 2
print(cnt)


x = int(input())
(m, r) = divmod(x, 11)
if r == 0:
	ans = 2 * m
elif r <= 6:
	ans = 2 * m + 1
else:
	ans = 2 * (m + 1)
print(ans)


import sys
sys.setrecursionlimit(10 ** 7)

def I():
	return int(sys.stdin.readline().rstrip())

def MI():
	return list(map(int, sys.stdin.readline().rstrip().split()))

def LI():
	return list(map(int, sys.stdin.readline().rstrip().split()))

def LI2():
	return list(map(int, sys.stdin.readline().rstrip()))

def S():
	return sys.stdin.readline().rstrip()

def LS():
	return list(sys.stdin.readline().rstrip().split())

def LS2():
	return list(sys.stdin.readline().rstrip())
x = I()
(q, r) = (x // 11, x % 11)
ans = 2 * q
if 1 <= r <= 6:
	ans += 1
elif r >= 7:
	ans += 2
print(ans)


import math
x = int(input())
a = x // 11
ama = x % 11
if ama == 0:
	print(a * 2)
elif ama <= 6:
	print(a * 2 + 1)
else:
	print(a * 2 + 2)


import math
import numpy as np
import sys
input = sys.stdin.readline

def main():
	x = int(input())
	ans = 2 * (x // 11)
	x = x % 11
	if x == 0:
		pass
	elif x < 7:
		ans += 1
	else:
		ans += 2
	print(ans)
main()


x = int(input())
ans_s = x // 11
ans_a = x % 11
if 1 <= ans_a <= 6:
	print(2 * ans_s + 1)
elif ans_a == 0:
	print(2 * ans_s)
else:
	print(2 * ans_s + 2)


N = int(input())
X = 2 * (N // 11)
if N % 11 > 6:
	X += 2
elif N % 11 > 0:
	X += 1
print(X)


N = int(input())
m = N % 11
ans = -(-N // 11) * 2
if 1 <= m <= 6:
	print(ans - 1)
else:
	print(ans)


x = int(input())
from math import ceil
ans = x // 11
x -= ans * 11
ans *= 2
if x > 0:
	if x <= 6:
		ans += 1
	else:
		ans += 2
print(ans)


import bisect
import itertools
import math
import random
from collections import Counter, deque, defaultdict
from functools import reduce
from operator import xor
mod = 10 ** 9 + 7

def lmi():
	return list(map(int, input().split()))

def main():
	x = int(input())
	ans = x // 11 * 2
	ans += math.ceil(x % 11 / 6)
	print(ans)

def __starting_point():
	main()
__starting_point()


x = int(input())
(q, r) = divmod(x, 11)
q *= 2
if 1 <= r <= 6:
	q += 1
elif r > 6:
	q += 2
print(q)


x = int(input())
point = x // 11 + 1
point *= 2
if x % 11 <= 6:
	point -= 1
if x % 11 == 0:
	point -= 1
print(point)


x = int(input())
(div, mod) = divmod(x, 11)
add = 0
if 0 < mod <= 6:
	add = 1
elif mod > 6:
	add = 2
print(div * 2 + add)


X = int(input())
t = X // (6 + 5)
a = X % (6 + 5)
b = 0
if a > 6:
	b = 2
elif a == 0:
	b = 0
else:
	b = 1
print(2 * t + b)


N = int(input())
r = N % 11
print(N // 11 * 2 + (0 if r == 0 else 1 if r <= 6 else 2))


N = int(input())
print(N // 11 * 2 + (N % 11 + 5) // 6)


x = int(input())
shou = x // 11
amari = x % 11
if amari == 0:
	print(shou * 2)
elif amari < 7:
	print(shou * 2 + 1)
else:
	print(shou * 2 + 2)


x = int(input())
from math import ceil
cnt = ceil(x / 11)
if 11 * cnt - 5 >= x:
	ans = cnt * 2 - 1
else:
	ans = cnt * 2
print(ans)