結果

問題 No.544 Delete 7
ユーザー Mcpu3Mcpu3
提出日時 2018-06-29 16:42:22
言語 Java
(openjdk 23)
結果
AC  
実行時間 435 ms / 1,000 ms
コード長 390 bytes
コンパイル時間 2,170 ms
コンパイル使用メモリ 76,868 KB
実行使用メモリ 56,544 KB
最終ジャッジ日時 2024-06-30 23:50:16
合計ジャッジ時間 13,471 ms
ジャッジサーバーID
(参考情報)
judge1 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 48
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

class no544{
	public static void main(String[] args) { 
		Scanner stdIn=new Scanner(System.in);
		int n=stdIn.nextInt(),i,a,b,t=1;
		for(i=1;t!=0;i+=13) {
			a=i;
			b=n-i;
			t=0;
			do {
				if(a%10==7) t++;
				a/=10;
			}while(a!=0);
			do {
				if(b%10==7) t++;
				b/=10;
			}while(b!=0);
		}
		System.out.print(i-13+" "+(n-i+13));
	}
}
0