QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#343999#7933. Build PermutationGuanYunchangCompile Error//C111.7kb2024-03-03 13:23:572024-03-03 13:23:57

Details

answer.code: In function ‘main’:
answer.code:12:5: error: variable-sized object may not be initialized
     long long array[n],num[n]={};
     ^~~~
answer.code:23:23: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘long long int’ [-Wformat=]
             printf(".%d ",arr[i][j]);
                      ~^   ~~~~~~~~~
                      %lld
answer.code:40:30: warning: format ‘%d’ expects argument of type ‘int’, but argument 3 has type ‘long long int’ [-Wformat=]
                 printf("*%d %d*\n",index,num[index]);
                             ~^           ~~~~~~~~~~
                             %lld
answer.code: In function ‘isUnique’:
answer.code:67:5: error: variable-sized object may not be initialized
     int temp_arr[n] = {}, temp_num[n] = {};
     ^~~
answer.code:67:5: error: variable-sized object may not be initialized
answer.code: In function ‘main’:
answer.code:10:5: warning: ignoring return value of ‘scanf’, declared with attribute warn_unused_result [-Wunused-result]
     scanf("%lld",&n);
     ^~~~~~~~~~~~~~~~
answer.code:14:9: warning: ignoring return value of ‘scanf’, declared with attribute warn_unused_result [-Wunused-result]
         scanf("%lld",&array[i]);
         ^~~~~~~~~~~~~~~~~~~~~~~