結果

問題 No.189 SUPER HAPPY DAY
ユーザー prog470prog470
提出日時 2015-04-22 00:40:24
言語 C90
(gcc 12.3.0)
結果
TLE  
実行時間 -
コード長 288 bytes
コンパイル時間 671 ms
コンパイル使用メモリ 20,736 KB
実行使用メモリ 13,760 KB
最終ジャッジ日時 2024-07-04 21:48:27
合計ジャッジ時間 7,213 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1 TLE * 1 -- * 1
other -- * 23
権限があれば一括ダウンロードができます
コンパイルメッセージ
main.c: In function ‘main’:
main.c:6:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
    6 |         scanf("%lld",&M);
      |         ^~~~~~~~~~~~~~~~
main.c:7:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
    7 |         scanf("%lld",&D);
      |         ^~~~~~~~~~~~~~~~

ソースコード

diff #

#include <stdio.h>

int main(void) {
	long long int M,D,x,y,c=0,i, j;
	
	scanf("%lld",&M);
	scanf("%lld",&D);
	
	for(j=1 ; j<=M ; j++)
	{
		for(i=1 ; i<=D ; i++ )
		{
			x = j/10 + j%10;
			y = i/10 + i%10;
			if(x == y)
			{
				c += 1;
			}
		}
		
	}
	
	printf("%lld\n",c);
	return 0;
}
0