/ SeriousOJ /

Record Detail

Time Exceeded


  
# Status Time Cost Memory Cost
#1 Accepted 1ms 504.0 KiB
#2 Time Exceeded ≥1095ms ≥384.0 KiB
#3 Accepted 1ms 320.0 KiB
#4 Accepted 1ms 320.0 KiB

Code

#include<bits/stdc++.h>
using namespace std;

int main(){

int n; cin>>n;

int cnt=0;

bool x=true;
while(x){

if(n>=2){

    if(n>=3){

        n-=3;
        cnt++;
        if(n==0){
            break;

        }
    }
    else{
        n-=2;
        cnt++;
        if(n==0){
            break;
        }
    }
}

}

cout<<cnt<<endl;

}

Information

Submit By
Type
Submission
Problem
P1106 too easy or three easy
Language
C++17 (G++ 13.2.0)
Submit At
2024-11-05 14:47:03
Judged At
2024-11-11 02:32:31
Judged By
Score
70
Total Time
≥1095ms
Peak Memory
≥504.0 KiB