Go: package main

import (
	"fmt"
)

func main() {
	var A, B, N int
	fmt.Scanf("%d %d %d", &A, &B, &N)

	login := 0
	week := 0
	sum := 0

	for sum < N {
		login++
		week++
		sum += A

		if week%7 == 0 {
			sum += B
			week = 0
		}
	}

	fmt.Println(login)
}

C++: #include"bits/stdc++.h"
using namespace std;

int CEIL(int a, int b) {return (a - 1) / b + 1;}

int main(){

	int A, B, C;
	cin >> A >> B >> C;
	int weekly = 7 * A + B;
	int answer = 0;

	int week = C / weekly;
	answer = week * 7;
	C -= week * weekly;

	for(int day = 0; day < 7 && C > 0; day++){
		C -= A;
		answer++;
	}

	cout << answer << endl;

	return 0;
}

C++: #include<iostream>
using namespace std;
int main(){
  int a,b,c,sum=0,coin=0;
  cin>>a>>b>>c;
  if(a<c){
    while(coin<c){
      sum++;
      coin=coin+a;
      if(sum%7==0){
        coin=coin+b;
      }
    }
  }
  else sum=1;
  cout<<sum<<endl;
}

C++: #include<cstdio>
#include<functional>
#include<algorithm>
#include<cstring>
using namespace std;
void func(int);
int main(void)
{
    int a,b,c,i,cnt;
    scanf("%d %d %d",&a,&b,&c);
    cnt=0;
    i=0;
    while(cnt<c) {
        i++;
        cnt+=a;
        if(i%7==0)  cnt+=b;
    }
    printf("%d\n",i);
    return 0;
}

C++: #include <iostream>
using namespace std;
int main(void){
    int a,b,c,d,e;
    d=0;
    e=0;
    cin>>a>>b>>c;
    while(1){
       if(d>=c){
           break;
       } 
       d=a+d;
       e=e+1;
       if(e%7==0){
           d=d+b;
       }
    }
    cout<<e<<endl;
}

C++: #include<iostream>

int main(){
    int a,b,c;
    std::cin>>a>>b>>c;
    int sum=0;
    int cnt=1;
    while(1){
        if(sum>=c)break;
        else{
            if(cnt%7==0){
            sum=sum+a+b;
            
            // std::cout<<"sum="<<sum<<" cnt="<<cnt<<"\n";
            cnt++;
        }
        else{
            sum+=a;
            // std::cout<<"sum="<<sum<<" cnt="<<cnt<<"\n";
            cnt++;
        }

        }
        
    }
    std::cout<<cnt-1<<"\n";
}

C++: #include <cstdio>
#include <iostream>


int main(void)
{
    int loginCoinA = 0;
    int weeklyCoinB = 0;
    int targetCoinC = 0;

    std::cin >> loginCoinA >> weeklyCoinB >> targetCoinC;

    int nowCoin = 0;
    int days = 0;
    while (targetCoinC > nowCoin) {
        days++;

        nowCoin += loginCoinA;
        if ((days % 7) == 0) {
            nowCoin += weeklyCoinB;
        }
    }

    std::cout << days << "\n";
    return 0;
}

C++: #include<bits/stdc++.h>
#include<cmath>
#include<algorithm>

using namespace std;

int main()
{
    int a=0,b=0,c=0;
    int coin=0;
    cin >> a >> b >> c;
    int loginbonasu=0;
    int count=0;
    while(coin<c)
    {   
        loginbonasu++;
        coin+=a;   
        if(loginbonasu%7==0)
        {
            coin+=b;
        }
        count++;
           
    }
    cout << count << endl;
    return(0);
}

C++: #include <iostream>

using namespace std;

int main() {
  int A, B, C;

  cin >> A;
  cin >> B;
  cin >> C;

  int day = 0;

  int sum = 0;

  while(1) {
    day++;
    sum += A;
    if (day % 7 == 0) {
      sum += B;
    } 

    if (sum >= C) {
      cout << day << endl;
      break;
    }
  }

  return 0;
}

C++: #define _USE_MATH_DEFINES
#define _CRT_SECURE_NO_WARNINGS

#include <iostream>
#include <string>
#include <sstream>
#include <iomanip>
#include <cmath>
#include <cstring>
#include <cstdlib>
#include <algorithm>
#include <stack>
#include <queue>
#include <vector>
#include <list>
#include <utility>
#include <numeric>

using namespace std;
typedef long long llong;
typedef unsigned long long ullong;

const ullong MOD = 1000000000 + 7;

int main()
{
	int a, b, c;
	cin >> a >> b >> c;

	int i;
	int s = 0;
	for (i = 1; ; i++)
	{
		s += (a + (i % 7 ? 0 : b));
		if (s >= c)
		{
			break;
		}
	}

	cout << i << endl;
}

C++: #include <iostream>
using namespace std;
int main(){
    int A,B,C;
    cin >> A >> B >> C ;
    int s = 0;
    int i = 1;
    while(s < C){
        s += A;
        if(i % 7 == 0){
            s += B;

        }
        i ++;
    }
    cout << i - 1 <<endl;
    return 0;
}

C++: #include <bits/stdc++.h>
using namespace std;
 
int main() {
    int A, B, C;
    cin >> A >> B >> C;
 
    int i = 0;
    int coin = 0;
 
    while( coin < C ) {
        ++i;
        coin += A;
 
        if( i % 7 == 0 ) {
            coin += B;
        }
    }
 
    cout << i << endl;
}

C++: #include<iostream>
using namespace std;

int main(){
  int a,b,c,sum = 0,i = 1;
  cin >> a >> b >> c;
  while(1){ 
    sum += a;
    if(i % 7 == 0){
      sum +=b;
    }
    if(sum >= c){
      break;
    }
    i++;
  }
  cout<<i<<endl;
  return 0;
}