Go: package main

import (
	"bufio"
	"fmt"
	"os"
	"strconv"
	"strings"
)

var scanner = bufio.NewScanner(os.Stdin)

func nextInt() (int, error) {
	return strconv.Atoi(nextString())
}

func nextString() string {
	scanner.Scan()
	return scanner.Text()
}

func printArr(arr []string) {
	fmt.Println(strings.TrimRight(fmt.Sprintf("%+v", arr)[1:], "]"))
}

func main() {
	scanner.Split(bufio.ScanWords)

	coinDaily, _ := nextInt()
	coinWeekly, _ := nextInt()
	coinTarget, _ := nextInt()

	coinCurrent := 0
	i := 0
	for i = 0; i <= 1000000; i++ {
		coinCurrent += coinDaily
		if (i+1)%7 == 0 {
			coinCurrent += coinWeekly
		}
		if coinCurrent >= coinTarget {
			break
		}
	}
	fmt.Println(i + 1)
}

Python: a,b,c=map(int,input().split())
W_C=int((7*a)+b)
#1週間の総コイン数

W=c//W_C
#何週間必要か

C=W_C*W
#W週間で得られたコイン数

if 7*a<c-C<W_C:
#1日で貰えるコイン×７<
#必要なコイン - W週間で得られたコイン数<
#1週間の総コイン数
    print((W+1)*7)

else:
    day=0
    coin=0
    while coin<c-C:
        coin+=a
        day+=1

    print(W*7+day)

Python: A, B, C = map(int, input(). split())

i = 1
sum = 0
while True:
    if i%7 == 0:
        sum += A + B
    if i%7 != 0:
        sum += A
    if sum >= C:
        break
    i += 1
    
print(i)

Python: A,B,C=(int(x) for x in input().split())

if B==0:
    x=C//A
    if C%A!=0:
        x=x+1
elif A>C:
    x=1
elif C//A<7:
    x=C//A+1
else:
    t=0
    y=A*7
    y=y+B
    z=C%y
    if 0<z<A:
        t=1
    z=z//A
    if z>7:
        t=7-z
    s=C//y
    s=s*7
    x=z+s+t
print(x)

Python: A,B,C = map(int, input().split())

days = int(C/(A+(B/7)))

while 1:
    coins = A* days + B * (days//7)

    if ( coins >= C):
        break
    else:
        days += 1

print(days)

Python: A,B,C=map(int,input().split())
coin=0
login=0
while coin<C:
    coin+=A
    login+=1
    if login%7==0:
        coin+=B
print(login)

Python: A,B,C=map(int,input().split())
coin=0
for day in range(1,C+1):
    coin += A
    if day % 7 == 0:
        coin +=B
    if coin >= C:
        break
print(day)

Python: def main():
    inp_line = input().split()
    
    login_coin = int(inp_line[0])       # ログインの度に得られるコイン
    add_coin = int(inp_line[1])         # 週ボーナスで追加で得られるコイン
    need_coin = int(inp_line[2])        # 少なくとも必要なコインの枚数
    
    # 入力チェック
    if not(1 <= login_coin <= 1000)\
       or not(0 <= add_coin <= 1000)\
       or not(1 <= need_coin <= 10 ** 6):
        print("入力が不正です。")
        return

    login_count = 0
    coin = 0
    while True:
        login_count += 1
        coin += login_coin
        # 7日Login
        if login_count % 7 == 0:
            coin += add_coin

        if coin >= need_coin:
            break

    print(login_count)

main()

Python: a,b,c=map(int,input().split())
x=0
y=0
while x<c:
    y+=1
    x+=a
    if y%7==0:
        x+=b
print(y)

Python: def main():
    a, b, c = (int(i) for i in input().split())
    ans = 0
    get_week = a*7 + b
    ans = 0
    if c % get_week == 0:
        ans = (c//get_week) * 7
        return print(ans)
    else:
        ans = (c//get_week) * 7
        c = c % get_week
        cnt = 0
        while c > 0:
            c -= a
            ans += 1
            cnt += 1
            if cnt == 7:
                c -= b
                cnt = 0
        return print(ans)


if __name__ == '__main__':
    main()

Python: A,B,C=map(int,input().split())

#print(A,B,C)

week=A*7+B
W=int(C/week)
W1=int(W*week)
r=int(C-W1)

a=int((r+A-1)/A)

if(a>7):
    a=7

a+=W*7
print(a)

Python: a,b,c=map(int,input().split())
d=1
coin=0
while coin<c:
    if d%7==0:
        coin+=b
    coin+=a
    d+=1
print(d-1)

Python: d, b, t = [int(x) for x in input().split()]

w = 7 * d + b

c = 0
c += (t // w) * 7
t %= w

if t >= 7*d:
    c +=7
    t = 0
else:
    c += t//d
    t %= d
    if t > 0:
        c += 1

print(c)

Python: a, b, c = map(int, input().split(" "))
ans = 0
if b == 0 :
    if c%a == 0:
        ans = c//a
    else:
        ans = c//a+1
else:
    unit = 7*a+b
    if c%unit==0:
        ans = 7*c//unit
    else:
        temp = c%unit
        if temp >= 7*a:
            ans = 7*(c//unit+1)
        else:
            if temp%a==0:
                ans = 7*(c//unit) + temp//a
            else:
                ans = 7*(c//unit) + temp//a + 1
print(ans)

Python: A, B, C = (int(x) for x in input().split())
D = C - (int(C/(7*A+B))*(A*7+B))
#print(D/A)
#print(int(C//(7*A+B)))
if D%A == 0:
    if D < 7*A:
        print(int(C/(7*A+B))*7 + int(D/A))
    else:
        print(int(C/(7*A+B))*7 + 7)
else:
    if D < 7*A:
        print(int(C/(7*A+B))*7 + int(D/A) + 1)
    else:
        print(int(C/(7*A+B))*7 + 7)

Python: a, b, c = map(int, input().split())
d, s = 0, 0

while s < c:
    d += 1
    if d % 7 == 0:
        s += b
    s += a

print(d)

Python: a, b, c = map(int,input().split())

day = 0
coin = 0
loginCont = 0
while True:
    day += 1
    loginCont += 1
    coin += a
    if day == 7:
        coin += b
        day = 0
        if coin >= c:
            break
    if coin >= c:
        break

print(loginCont)

Python: import math
a,b,c=map(int,input().split())

m=a*7+b

if c<a*7:
    print(math.ceil(c/a))
else:
    n=math.floor(c/m)
    p=c-m*n
    if p/a<7:
        x=n*7+math.ceil(p/a)
    else:
        x=n*7+7

    print(x)

Python: A, B, C = map(int, input().split())
coin = 0
day = 1
while coin < C :
    coin += A
    if day % 7 == 0 :
        coin += B
    day += 1
print(day-1)

Python: # -*- coding: utf-8 -*-
coin_day, coin_week, goal = map(int, input().split())
total_coin_per_week = coin_week + (7 * coin_day)
res_week, rest_coin = divmod(goal, total_coin_per_week)

res_day, residual = divmod(rest_coin, coin_day)
if residual >= 1:
    res_day += 1
if res_day >= 7:
    res_day = 7

print(res_week * 7 + res_day)

Python: a,b,c = map(int,input().split())
ans = 0
ans += c//(a*7 +b)*7
c %= (a*7+b)
ans += min(7,c//a)
if c%a and c//a <7:
    ans += 1
print(ans)

Python: a, b, c = map(int, input().split())
week = a * 7 + b
d = c // week
ans = d * 7
c -= d * week

cnt = 0
while(c > 0):
    c -= a
    ans += 1
    cnt += 1
    if(cnt == 7):
        c -= b
        cnt = 0
print(ans)

Python: a,b,c=map(int,input().split())
day=0
coin=0
 
while coin<c:
    day+=1
    coin+=a
    if day%7==0:
        coin+=b
print(day)

Python: #ゲームのログイン（1日1回）でコイン獲得
# a:coins/1day b:bounus/week c:goal of gained coins
# 毎日ログイン前提
a,b,c = list(map(int,input().split()))


days_needed = 0
coins = 0

flag = True
while flag:  
    days_needed += 1
    coins += a
    if days_needed % 7 == 0:
        coins += b

    if coins >= c:
        flag=False

print(days_needed)

Python: a,b,c = map(int,input().split())

ok = 100000000
ng = 0
while ok - ng > 1:
    m = (ok + ng) // 2
    ge = m * a + (m // 7) * b
    if ge >= c:
        ok = m
    else:
        ng = m
print(ok)

Python: A,B,C=map(int,input().split())
sum=0
i=0
while True:
    sum+=A
    i+=1
    if sum>=C:
        print(i)
        break
    if i%7==0:
        sum+=B
        if sum>=C:
            print(i)
            break

Python: A, B, C = map(int,input().split())

coin = 0
for day in range(1, C+1):
    coin += A
    if day % 7 == 0:
        coin += B
    if coin >= C:
        break
print(day)

Python: l = list(map(int,input().split()))
coins = 0
login_times = 0
while True:
    coins += l[0]
    login_times += 1
    if login_times%7==0:
        coins += l[1]
    if coins>=l[2]:
        print(login_times)
        break

Python: #john_doe
In=list(map(int,input().split()))
cnt=0
sum=0
while(sum<In[2]):
    sum+=In[0]
    cnt+=1
    if(cnt%7==0):
        sum+=In[1]
print(cnt)

Python: a,b,c=map(int,input().split())

if -(-c//a)<=7:
    print(-(-c//a))
elif b+7*a>=c:
    print('7')
else:
    d=c//(7*a+b)
    e=c%(7*a+b)
    if (7*a+b)-e>=b:
        f=-(-e//a)
        print(d*7+f)
    else:
        print(7*d+7)

Python: import math
A,B,C = map(int, input().split())
x=C//(7*A+B)
y=C-(7*A+B)*x
if y <= A*6:
    print(x*7+math.ceil(y/A))
else:
    print(x*7+7)

Python: inputs = input().split(" ")

print(math.ceil(inputs[2]/(inputs[0]+(inputs[1]/7))))