Submission #57201603


Source Code Expand

///In the name of ALLAH, The Most Gracious and The Most Merciful
///Praise be to ALLAH

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

const int sz = 1e5 + 10;
int ar[sz];

using ll = long long;

#define el "\n"
#define optimize() ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0);
#define testCase int __; cin >> __; while(__--)
#define fraction() cout.unsetf(ios::floatfield); cout.precision(10); cout.setf(ios::fixed,ios::floatfield);

void solve()
{
    int n, k; cin >> n >> k;;

    for(int i = 0; i < n; i++)
        cin >> ar[i];
    
    for(int i = n - k; i < n; i++)
        cout << ar[i] << " ";

    for(int i = 0; i < n - k; i++)
        cout << ar[i] << " ";


}
int main()
{
    optimize();
    
    //testCase
        solve();

    return 0;
}

Submission Info

Submission Time
Task A - Cut
User InFi4D_0
Language C++ 20 (gcc 12.2)
Score 100
Code Size 800 Byte
Status AC
Exec Time 1 ms
Memory 3552 KiB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 100 / 100
Status
AC × 2
AC × 10
Set Name Test Cases
Sample sample_01.txt, sample_02.txt
All random_01.txt, random_02.txt, random_03.txt, random_04.txt, random_05.txt, random_06.txt, random_07.txt, random_08.txt, sample_01.txt, sample_02.txt
Case Name Status Exec Time Memory
random_01.txt AC 1 ms 3384 KiB
random_02.txt AC 1 ms 3552 KiB
random_03.txt AC 1 ms 3320 KiB
random_04.txt AC 1 ms 3424 KiB
random_05.txt AC 1 ms 3408 KiB
random_06.txt AC 1 ms 3444 KiB
random_07.txt AC 1 ms 3552 KiB
random_08.txt AC 1 ms 3380 KiB
sample_01.txt AC 1 ms 3400 KiB
sample_02.txt AC 1 ms 3400 KiB