제출 #167320

#제출 시각아이디문제언어결과실행 시간메모리
167320AKaan37Izlet (COI19_izlet)C++17
25 / 100
1091 ms78368 KiB
//Sani buyuk Osman Pasa Plevneden cikmam diyor. //FatihSultanMehmedHan //Abdulhamid Han //Bismillahirrahmanirrahim //█▀█─█──█──█▀█─█─█ //█▄█─█──█──█▄█─█▄█ //█─█─█▄─█▄─█─█─█─█ #pragma GCC optimize ("O3") #pragma GCC target ("sse4") #include <bits/stdc++.h> using namespace std; typedef long long lo; typedef pair< lo,lo > PII; #define fi first #define se second #define mp make_pair #define pb push_back #define fio() ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL) #define FOR for(lo i=1;i<=n;i++) #define mid ((start+end)/2) #define ort ((bas+son)/2) const lo MAX = -1000000000000000000; const lo MIN = 1000000000000000000; const lo inf = 1000000000; const lo KOK = 100000; const lo LOG = 30; const lo li = 500005; const lo mod = 1000000007; lo n,m,b[li],a[3005][3005],k,flag,t,score,last[li]; lo cev; string s; vector<lo> v; int main(void){ scanf("%lld",&score); scanf("%lld",&n); FOR{ for(lo j=1;j<=n;j++)scanf("%lld",&a[i][j]); } b[1]=1; lo yaz=1; for(lo i=2;i<=n;i++){ flag=0; for(int j=i-1;j>=1;j--){ if(a[i][j]==a[i-1][j]){flag=1;b[i]=b[j];break;} } if(!flag) b[i]=++yaz; //~ else if(b[i]==0) b[i]=b[i-1]; for(int j=1;j<=i;j++){ last[j]=a[i][j]; } } FOR printf("%lld ",b[i]); printf("\n"); for(lo i=1;i<n;i++){ printf("%lld %lld\n",i,i+1); } return 0; }

컴파일 시 표준 에러 (stderr) 메시지

izlet.cpp: In function 'int main()':
izlet.cpp:42:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
  scanf("%lld",&score);
  ~~~~~^~~~~~~~~~~~~~~
izlet.cpp:43:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
  scanf("%lld",&n);
  ~~~~~^~~~~~~~~~~
izlet.cpp:45:28: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
   for(lo j=1;j<=n;j++)scanf("%lld",&a[i][j]);
                       ~~~~~^~~~~~~~~~~~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...