結果
| 問題 | No.1224 I hate Sqrt Inequality | 
| コンテスト | |
| ユーザー |  ks2m | 
| 提出日時 | 2020-09-11 21:31:32 | 
| 言語 | Java (openjdk 23) | 
| 結果 | 
                                WA
                                 
                            (最新) 
                                AC
                                 
                            (最初) | 
| 実行時間 | - | 
| コード長 | 384 bytes | 
| コンパイル時間 | 2,019 ms | 
| コンパイル使用メモリ | 74,348 KB | 
| 実行使用メモリ | 54,460 KB | 
| 最終ジャッジ日時 | 2024-06-11 21:16:51 | 
| 合計ジャッジ時間 | 4,733 ms | 
| ジャッジサーバーID (参考情報) | judge3 / judge4 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 2 | 
| other | AC * 12 WA * 1 | 
ソースコード
import java.util.Scanner;
public class Main {
	public static void main(String[] args) throws Exception {
		Scanner sc = new Scanner(System.in);
		long a = sc.nextLong();
		long b = sc.nextLong();
		sc.close();
		int cnt = 0;
		while (cnt < 100) {
			a %= b;
			if (a == 0) {
				System.out.println("No");
				return;
			}
			a *= 10;
			cnt++;
		}
		System.out.println("Yes");
	}
}
            
            
            
        