結果
| 問題 | 
                            No.9002 FizzBuzz(テスト用)
                             | 
                    
| ユーザー | 
                             kaedamakun
                         | 
                    
| 提出日時 | 2015-05-31 13:57:23 | 
| 言語 | C++11(廃止可能性あり)  (gcc 13.3.0)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 373 bytes | 
| コンパイル時間 | 109 ms | 
| コンパイル使用メモリ | 22,272 KB | 
| 実行使用メモリ | 6,944 KB | 
| 最終ジャッジ日時 | 2024-07-06 12:55:06 | 
| 合計ジャッジ時間 | 479 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge1 / judge3 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 1 WA * 3 | 
コンパイルメッセージ
main.cpp: In function ‘int main()’:
main.cpp:6:15: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
    6 |          scanf("%d",&N);
      |          ~~~~~^~~~~~~~~
            
            ソースコード
#include<stdio.h>
int main()
{
	int N=0;
	int checker;
	 scanf("%d",&N);
	 for(int i=1;i<=N;i++)
	 {
	 	checker=i%15;
		if(checker==0)
		{
			printf("FizzBuzz\n");
		}
		else
		{
			checker=i%5;
			if(checker==0)
			{
				printf("Buzz\n");
			}
			checker=i%3;
			if(checker==0)
			{
				printf("Fizz\n");
			}
			else
			{
				printf("%d\n",i);
			}
	 	}
	 }
	 return 0;
}
            
            
            
        
            
kaedamakun