提出 #66979062


ソースコード 拡げる

#include<stdio.h>
#include<math.h>
#include<stdlib.h>
#include <string.h>

char A[200000][100000];

int main(){
    int n,q;
   	scanf("%d%d",&n,&q);
	int type;

	for(int i=0;i<=n;i++){
		sprintf(A[i],"%s","");
	}
	int p;
	char s[1000000];
    for(int i=0;i<q;i++){
		scanf("%d",&type);
		if(type==1){
   			scanf("%d",&p);
			strcpy(A[p],A[0]);

		}
		if(type==2){
			scanf("%d",&p);
			scanf("%s",s);
			strcat(A[p],s);

		}
		if(type==3){
			scanf("%d",&p);
			strcpy(A[0],A[p]);
		}
	}
	printf("%s",A[0]);
	
    return 0;
}

提出情報

提出日時
問題 D - Conflict 2
ユーザ makijin
言語 C (gcc 12.2.0)
得点 0
コード長 565 Byte
結果 RE
実行時間 0 ms
メモリ 1628 KiB

コンパイルエラー

Main.c: In function ‘main’:
Main.c:10:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   10 |         scanf("%d%d",&n,&q);
      |         ^~~~~~~~~~~~~~~~~~~
Main.c:19:17: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   19 |                 scanf("%d",&type);
      |                 ^~~~~~~~~~~~~~~~~
Main.c:21:25: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   21 |                         scanf("%d",&p);
      |                         ^~~~~~~~~~~~~~
Main.c:26:25: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   26 |                         scanf("%d",&p);
      |                         ^~~~~~~~~~~~~~
Main.c:27:25: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   27 |                         scanf("%s",s);
      |                         ^~~~~~~~~~~~~
Main.c:32:25: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   32 |                         scanf("%d",&p);
      |                         ^~~~~~~~~~~~~~

ジャッジ結果

セット名 Sample All
得点 / 配点 0 / 0 0 / 425
結果
RE × 3
RE × 49
セット名 テストケース
Sample 00_sample_00.txt, 00_sample_01.txt, 00_sample_02.txt
All 00_sample_00.txt, 00_sample_01.txt, 00_sample_02.txt, 01_random_00.txt, 01_random_01.txt, 01_random_02.txt, 01_random_03.txt, 01_random_04.txt, 01_random_05.txt, 01_random_06.txt, 01_random_07.txt, 01_random_08.txt, 01_random_09.txt, 01_random_10.txt, 01_random_11.txt, 01_random_12.txt, 01_random_13.txt, 01_random_14.txt, 01_random_15.txt, 02_random2_00.txt, 02_random2_01.txt, 02_random2_02.txt, 02_random2_03.txt, 02_random2_04.txt, 02_random2_05.txt, 02_random2_06.txt, 02_random2_07.txt, 02_random2_08.txt, 02_random2_09.txt, 02_random2_10.txt, 02_random2_11.txt, 02_random2_12.txt, 02_random2_13.txt, 02_random2_14.txt, 02_random2_15.txt, 03_random3_00.txt, 03_random3_01.txt, 03_random3_02.txt, 03_random3_03.txt, 04_random4_00.txt, 04_random4_01.txt, 05_random5_00.txt, 05_random5_01.txt, 06_handmade_00.txt, 06_handmade_01.txt, 06_handmade_02.txt, 06_handmade_03.txt, 06_handmade_04.txt, 06_handmade_05.txt
ケース名 結果 実行時間 メモリ
00_sample_00.txt RE 0 ms 1628 KiB
00_sample_01.txt RE 0 ms 1444 KiB
00_sample_02.txt RE 0 ms 1616 KiB
01_random_00.txt RE 0 ms 1508 KiB
01_random_01.txt RE 0 ms 1504 KiB
01_random_02.txt RE 0 ms 1620 KiB
01_random_03.txt RE 0 ms 1616 KiB
01_random_04.txt RE 0 ms 1624 KiB
01_random_05.txt RE 0 ms 1504 KiB
01_random_06.txt RE 0 ms 1624 KiB
01_random_07.txt RE 0 ms 1564 KiB
01_random_08.txt RE 0 ms 1620 KiB
01_random_09.txt RE 0 ms 1504 KiB
01_random_10.txt RE 0 ms 1504 KiB
01_random_11.txt RE 0 ms 1444 KiB
01_random_12.txt RE 0 ms 1444 KiB
01_random_13.txt RE 0 ms 1508 KiB
01_random_14.txt RE 0 ms 1508 KiB
01_random_15.txt RE 0 ms 1628 KiB
02_random2_00.txt RE 0 ms 1508 KiB
02_random2_01.txt RE 0 ms 1448 KiB
02_random2_02.txt RE 0 ms 1444 KiB
02_random2_03.txt RE 0 ms 1620 KiB
02_random2_04.txt RE 0 ms 1616 KiB
02_random2_05.txt RE 0 ms 1444 KiB
02_random2_06.txt RE 0 ms 1568 KiB
02_random2_07.txt RE 0 ms 1616 KiB
02_random2_08.txt RE 0 ms 1616 KiB
02_random2_09.txt RE 0 ms 1612 KiB
02_random2_10.txt RE 0 ms 1504 KiB
02_random2_11.txt RE 0 ms 1476 KiB
02_random2_12.txt RE 0 ms 1444 KiB
02_random2_13.txt RE 0 ms 1616 KiB
02_random2_14.txt RE 0 ms 1612 KiB
02_random2_15.txt RE 0 ms 1504 KiB
03_random3_00.txt RE 0 ms 1620 KiB
03_random3_01.txt RE 0 ms 1620 KiB
03_random3_02.txt RE 0 ms 1508 KiB
03_random3_03.txt RE 0 ms 1508 KiB
04_random4_00.txt RE 0 ms 1504 KiB
04_random4_01.txt RE 0 ms 1504 KiB
05_random5_00.txt RE 0 ms 1504 KiB
05_random5_01.txt RE 0 ms 1504 KiB
06_handmade_00.txt RE 0 ms 1444 KiB
06_handmade_01.txt RE 0 ms 1504 KiB
06_handmade_02.txt RE 0 ms 1508 KiB
06_handmade_03.txt RE 0 ms 1508 KiB
06_handmade_04.txt RE 0 ms 1504 KiB
06_handmade_05.txt RE 0 ms 1508 KiB