Submission #5818525


Source Code Expand

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

int main(){
  int n,i;
  cin >> n;
  if(n == 1){
    i = 1;
  }
  else if(2<=n&&n<=3){
    i=2;
  }
  else if(4<=n&&n<=7){
    i=4;
  }
  else if(8<=n&&n<=15){
    i=8;
  }
  else if(16<=n&&n<=31){
    i=16;
  }
  else if(32<=n&&n<=63){
    i=32;
  }
  else {
    i=64;
  }
  
  cout << i << endl;
}

Submission Info

Submission Time
Task B - Break Number
User touchico
Language C++14 (GCC 5.4.1)
Score 200
Code Size 375 Byte
Status
Exec Time 1 ms
Memory 256 KB

Test Cases

Set Name Score / Max Score Test Cases
Sample 0 / 0 example0, example1, example2, example3
All 200 / 200 example0, example1, example2, example3, handmade0, handmade1, handmade2, rand0, rand1, rand2, rand3, rand4, rand5, rand6, rand7, rand8, rand9
Case Name Status Exec Time Memory
example0 1 ms 256 KB
example1 1 ms 256 KB
example2 1 ms 256 KB
example3 1 ms 256 KB
handmade0 1 ms 256 KB
handmade1 1 ms 256 KB
handmade2 1 ms 256 KB
rand0 1 ms 256 KB
rand1 1 ms 256 KB
rand2 1 ms 256 KB
rand3 1 ms 256 KB
rand4 1 ms 256 KB
rand5 1 ms 256 KB
rand6 1 ms 256 KB
rand7 1 ms 256 KB
rand8 1 ms 256 KB
rand9 1 ms 256 KB