Go: package main

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

func oneLineInt(s string) []int {
	temp := strings.Split(s, " ")
	// fmt.Println(len(temp))
	ints := []int{}
	for _, elem := range(temp) {
		int_elem, _ := strconv.Atoi(elem)
		ints = append(ints, int_elem)
	}
	return ints
}

func coinCount(ints []int) int {
	cons := ints[0]
	bonus := ints[1]
	target := ints[2]
	count := 0
	day := 0
	var dc int
	for day_count, _ := range(make([]int, target)) {
		day++
		if day % 7 == 0 {
			count += bonus
		}
		count += cons
		if count >= target {
			dc = day_count + 1
			break
		}
	}
	return dc
}

func main() {
	scanner := bufio.NewScanner(os.Stdin)
	var txt string
	if scanner.Scan() {
		txt = scanner.Text()
	}
	ints := oneLineInt(txt)
	// fmt.Println(ints[1])
	// fmt.Println(reflect.TypeOf(ints[0]))
	result := coinCount(ints)
	fmt.Println(result)
}

Python: import sys

sys.setrecursionlimit(10 ** 6)
int1 = lambda x: int(x) - 1
p2D = lambda x: print(*x, sep="\n")
def MI(): return map(int, sys.stdin.readline().split())
def LI(): return list(map(int, sys.stdin.readline().split()))
def LLI(rows_number): return [LI() for _ in range(rows_number)]

def main():
    a,b,c=MI()
    week,r=divmod(c,7*a+b)
    day=(r+a-1)//a
    print(week*7+min(7,day))

main()

Python: A,B,C=map(int,input().split())
coin=0
for day in range(1,1+C): #1日からC日まで繰り返す
    coin=coin+A
    if day%7==0: 
        coin=coin+B #七日経ったらB枚のコインも追加
    if coin>=C:
        break #coinがC枚より多くなったら繰り返し終了
print(day)

Python: a,b,c=map(int,input().split())
nowpoint=0
day=0
while 1:
    if c-nowpoint<=a*6:
        day+=(c-nowpoint+a-1)//a
        break
    elif c-nowpoint<=a*7+b:
        day+=7
        break
    day+=7
    nowpoint+=a*7+b
print(day)

Python: # coding: utf-8
# Your code here!

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: a,b,c = map(int,input().split())

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

Python: 
import sys
from math import ceil

def solve(a, b, c):
    q, r = divmod(c, (a*7 + b))
    return q * 7 + min(ceil(r / a), 7)


def main(args):
    a, b, c = map(int, input().split())
    ans = solve(a, b, c)
    print(ans)


if __name__ == '__main__':
    main(sys.argv[1:])

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: a,b,c=map(int,input().split())
ans=0
while c>0:
	c-=a
	if ans%7==6:
		c-=b
	ans+=1
print(ans)

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

Python: sum_coins = 0
coin_day, coin_weekly, coin_needed = map(int, input().split())
day = 0

while sum_coins < coin_needed:
    day +=1
    sum_coins += coin_day

    if day % 7 == 0:
        sum_coins += coin_weekly
print(day)

Python: inputs = input().split()
a = int(inputs[0])
b = int(inputs[1])
c = int(inputs[2])

y = 7*c / (7*a + b)
if y - int(y) > 0:
    x = int(y) + 1
else:
    x = int(y)


while True:
    if a*x + int(x/7) * b >= c:
        print(x)
        break
    else:
        x+=1

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

Python: def getInput():
    (a, b, c) = (int(i) for i in input().split(" "))
    return a, b, c

a, b, c = getInput()

n_weeklylogin = 0
n_dailylogin = 0
weekly_gain = 7*a+b

n_weeklylogin = c//weekly_gain
total_bonus = n_weeklylogin*weekly_gain

if total_bonus >= c:
    print(n_weeklylogin*7)
else:
    n_dailylogin = -(-(c-total_bonus)//a)
    print(n_weeklylogin*7 + (n_dailylogin>=7)*7 + (n_dailylogin<7)*(n_dailylogin))

Python: A, B, C = map(int, input().split())
x = A * 7 + B
ans = C // x * 7
C = C % x
y = C // A
if C % A > 0:
  y += 1
if y > 7:
  y = 7
ans += y
print(ans)

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

Python: def eval(A, B, C):
    rest = C
    count = 0
    
    while True:
        for i in range(7):
            rest -= A
            if i == 6:
                rest -= B
                
            count += 1
            if rest <= 0:
                return count


A, B, C = tuple(map(int, input().split()))
print(eval(A, B, C))

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: A, B, C = (int(x) for x in input().split())
d = A*6

if C<d:
    if C%A == 0:
        print(C//A)
    if C%A > 0 :
        print(C//A+1)

if C>=d:
    D = A*7+B
    E = C%D
    F = C//D
    x = E//A
    y = E%A
    if x < 7 :
        if y == 0:
            print(F*7+x)
        if y > 0 :
            print(F*7+x+1)
    if x >= 7:
        print((F+1)*7)

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: a, b, c = map(int, input().split())
ans = c // (a * 7 + b) * 7
c %= a * 7 + b
ans += min(7, (c + a - 1) // a)
print(ans)

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

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

Python: import math

daily_coin, bonus_coin, goal = (int(x) for x in input().split())

days = goal // daily_coin
weekly_coin = daily_coin * 7 + bonus_coin

if days < 7:
    print(math.ceil(goal / daily_coin))

elif days == 7:
    if daily_coin * 7 < goal < weekly_coin:
        print(7)
        
else:
    week = goal // weekly_coin
    rest_coin = goal - weekly_coin * week
    if (daily_coin * 7 < rest_coin < weekly_coin) or (daily_coin * 6 < rest_coin < weekly_coin):
        rest_days = 7
        print(week * 7 + rest_days)
    else:
        rest_days = math.ceil(rest_coin / daily_coin)
        print(week * 7 + rest_days)

Python: a,b,c=map(int,input().split())
print(c//(7*a+b)*7+(7 if c%(7*a+b)>6*a else (c%(7*a+b)+a-1)//a))

Python: A,B,C=map(int,input().split())
if C<7*A+B:         #1週間目でおわる
    if  A*7<C and C<A*7+B: #実は1週目の日曜日に終わる
        print(7)
    else:    
        if C%A==0:          
            print(C//A)
        else:               #あまりがあったら＋１
            print(C//A+1) 
else:                       #2週間目以降
    if C%((7*A)+B)==0:              #日曜日に終わる
        print((C//((7*A)+B))*7)
    else :
        if C%((7*A)+B)>=7*A and C%((7*A)+B)<7*A+B: #実は日曜日に終わる
            print((C//((7*A)+B)+1)*7)
        else:
            if (C%((7*A)+B))%A==0 :
                print(((C//((7*A)+B))*7)+((C%((7*A)+B))//A))
            else:                       #余りがあったら+１
             print(((C//((7*A)+B))*7)+((C%((7*A)+B)))//A+1)

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

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

ans = c // (a * 7 + b) * 7
c %= a * 7 + b
ans += min(7, (c + a - 1) // a)

print(ans)