1 条题解

  • 1
    @ 2026-3-1 14:26:35

    #include <bits/stdc++.h> using namespace std; int main() {

    int a;
    cin >> a;
    int n = 10;
    int t = 0;
    int m = 3;
    while (1) {
    	if ( m == 1 || m == 2) {
    		n = n + 7;
    	}
    	n = n - 1;
    	m += 1;
    	m %= 7;
    	t = t + 1;
    	if (n == a) {
    		cout << t;
    		return 0;
    	}
    }
    
    return 0;
    

    }

    信息

    ID
    2568
    时间
    1000ms
    内存
    256MiB
    难度
    3
    标签
    递交数
    30
    已通过
    15
    上传者