結果
| 問題 | 
                            No.889 素数!
                             | 
                    
| コンテスト | |
| ユーザー | 
                             | 
                    
| 提出日時 | 2020-08-14 23:10:16 | 
| 言語 | Python3  (3.13.1 + numpy 2.2.1 + scipy 1.14.1)  | 
                    
| 結果 | 
                             
                                AC
                                 
                             
                            
                         | 
                    
| 実行時間 | 31 ms / 2,000 ms | 
| コード長 | 347 bytes | 
| コンパイル時間 | 124 ms | 
| コンパイル使用メモリ | 12,800 KB | 
| 実行使用メモリ | 11,008 KB | 
| 最終ジャッジ日時 | 2024-10-10 16:36:27 | 
| 合計ジャッジ時間 | 3,734 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge2 / judge1 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 61 | 
ソースコード
n = int(input())
def is_prime(n):
    for i in range(2, int(n ** 0.5) + 1):
        if n % i == 0:
            return False
    return n != 1
if is_prime(n) and n != 0:
    print('Sosu!')
elif n in [4, 9, 16, 25, 36, 49]:
    print('Heihosu!')
elif n in [8, 27]:
    print('Ripposu!')
elif n in [6, 28]:
    print('Kanzensu!')
else:
    print(n)