結果

問題 No.1224 I hate Sqrt Inequality
ユーザー harurunharurun
提出日時 2020-09-11 21:32:58
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 17 ms / 2,000 ms
コード長 604 bytes
コンパイル時間 389 ms
コンパイル使用メモリ 10,772 KB
実行使用メモリ 8,120 KB
最終ジャッジ日時 2023-09-02 14:41:27
合計ジャッジ時間 1,432 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 17 ms
8,012 KB
testcase_01 AC 17 ms
7,952 KB
testcase_02 AC 16 ms
7,980 KB
testcase_03 AC 16 ms
7,960 KB
testcase_04 AC 16 ms
7,888 KB
testcase_05 AC 16 ms
8,040 KB
testcase_06 AC 16 ms
8,120 KB
testcase_07 AC 16 ms
8,064 KB
testcase_08 AC 17 ms
7,960 KB
testcase_09 AC 16 ms
7,968 KB
testcase_10 AC 16 ms
8,100 KB
testcase_11 AC 16 ms
8,060 KB
testcase_12 AC 17 ms
8,000 KB
testcase_13 AC 16 ms
7,924 KB
testcase_14 AC 16 ms
8,064 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

'''
Created on 2020/09/11

@author: harurun
'''
def Yn(t):
  if t:print("Yes")
  else:print("No")
  return

def main():
  import math
  import sys
  pin=sys.stdin.readline
  pout=sys.stdout.write
  perr=sys.stderr.write
  
  a,b=map(int,pin().split())
  t=math.gcd(a,b)
  a=a//t 
  b=b//t 
  if b==1:
    print("No")
    return 
  while True:
    if b%10==0:
      b=b//10
    else:
      break
  while True:
    if b%5==0:
      b=b//5
    else:
      break
  while True:
    if b%2==0:
      b=b//2
    else:
      break
  Yn(b!=1)
  return 
main()

#わかりませんこれで許してください
  
0