結果

問題 No.494 yukicoder
ユーザー sasa
提出日時 2025-03-13 16:57:08
言語 C
(gcc 13.3.0)
結果
RE  
実行時間 -
コード長 236 bytes
コンパイル時間 362 ms
コンパイル使用メモリ 23,296 KB
実行使用メモリ 7,328 KB
最終ジャッジ日時 2025-03-13 16:57:11
合計ジャッジ時間 2,518 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample RE * 2
other RE * 7
権限があれば一括ダウンロードができます
コンパイルメッセージ
main.c: In function ‘main’:
main.c:7:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
    7 |         scanf("%s",str);
      |         ^~~~~~~~~~~~~~~

ソースコード

diff #

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

int main(){
	char *ans = "yukicoder";
	char *str;
	scanf("%s",str);
	int len = strlen(ans);
	
	while(*str != '\0'){
		if(ans != str){
			printf("%s",ans);
			return 0;
		}
		*ans++;
		*str++;
	}
}
0