Free Contest 134 - MAXMOD

View as PDF

Submit solution

Points: 0.70 (partial)
Time limit: 1.0s
Memory limit: 512M

Problem type
Allowed languages
C, C++, Go, Java, Kotlin, Pascal, PyPy, Python, Rust, Scratch

In case the statement didn't load correctly, you can download the statement here: Statement

Lưu ý: các bạn không nhập, xuất dữ liệu bằng file kể cả khi đề bài có yêu cầu. Đọc, ghi dữ liệu được thực hiện ở stdin và stdout.


Comments

Please read the guidelines before commenting.



  • -4
    quygiaminh123  commented on Dec. 31, 2024, 1:01 p.m.

    include<bits/stdc++.h>

    using namespace std; int main() { long long t; cin>>t; while(t--) { unsigned long long n; cin>>n; cout<<(n/2)+1<<endl; } }


  • -2
    thanhhtung3008  commented on Nov. 10, 2024, 12:59 p.m.

    n = 9 thì sao x lại là 5 nhỉ đáng lẽ x = 4 chứ nhỉ 9%5 < 9%4 mà


  • -11
    _______  commented on Nov. 3, 2023, 8:09 a.m. edit 3

    This comment is hidden due to too much negative feedback. Show it anyway.


  • -3
    vendettas  commented on Sept. 15, 2023, 4:37 p.m.

    ví dụ bài này có sai không vậy chứ với x<n thì n%x lớn nhất với n = 6 là x = 5 chứ?


    • 1
      ngockhue  commented on Sept. 25, 2023, 11:36 a.m.

      với n=6 thì 6%5=1 còn 6%4 = 2 nên output là 4 đúng r nhé


  • -22
    khai02042008  commented on Dec. 31, 2022, 1:50 a.m.

    This comment is hidden due to too much negative feedback. Show it anyway.


    • -14
      _______  commented on Nov. 3, 2023, 8:19 a.m. edited

      This comment is hidden due to too much negative feedback. Show it anyway.