結果

問題 No.537 ユーザーID
ユーザー syuki791syuki791
提出日時 2017-07-02 14:00:05
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 581 bytes
コンパイル時間 2,795 ms
コンパイル使用メモリ 77,120 KB
実行使用メモリ 44,080 KB
最終ジャッジ日時 2024-04-15 11:56:18
合計ジャッジ時間 9,152 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 134 ms
41,800 KB
testcase_01 AC 136 ms
41,320 KB
testcase_02 AC 132 ms
41,208 KB
testcase_03 AC 134 ms
41,396 KB
testcase_04 AC 135 ms
41,136 KB
testcase_05 AC 136 ms
41,552 KB
testcase_06 WA -
testcase_07 WA -
testcase_08 AC 133 ms
41,544 KB
testcase_09 AC 136 ms
41,280 KB
testcase_10 AC 133 ms
41,300 KB
testcase_11 AC 136 ms
41,620 KB
testcase_12 AC 137 ms
41,092 KB
testcase_13 WA -
testcase_14 WA -
testcase_15 AC 135 ms
41,280 KB
testcase_16 AC 131 ms
41,192 KB
testcase_17 WA -
testcase_18 AC 167 ms
41,548 KB
testcase_19 AC 155 ms
41,316 KB
testcase_20 AC 157 ms
41,292 KB
testcase_21 AC 162 ms
41,704 KB
testcase_22 AC 170 ms
41,392 KB
testcase_23 AC 171 ms
41,648 KB
testcase_24 AC 144 ms
41,460 KB
testcase_25 AC 185 ms
42,012 KB
testcase_26 AC 193 ms
41,584 KB
testcase_27 AC 167 ms
41,716 KB
testcase_28 AC 189 ms
42,840 KB
testcase_29 AC 213 ms
43,484 KB
testcase_30 AC 207 ms
43,496 KB
testcase_31 WA -
testcase_32 AC 161 ms
41,716 KB
testcase_33 WA -
testcase_34 AC 170 ms
41,560 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class Main {
	
	public static void main(String[] args){
		Scanner s = new Scanner(System.in);
		String str = s.next();
		s.close();
		long n = Long.parseLong(str);
		long count = 0;
	
		long heihou = (long) Math.floor(Math.sqrt((double)n));
		
		for(long i= 1;i<=heihou;i++){
			if(n%i==0){
				count++;
				String s1 = String.valueOf(i);
				String s2 = String.valueOf(n/i);
				long n1 = Long.parseLong(s1+s2);
				long n2 = Long.parseLong(s2+s1);
				if(n1 != n2){
				count++;
				}
				
			}
		}
		
			
		System.out.println(count);
		
	}

}
0