結果
| 問題 | 
                            No.197 手品
                             | 
                    
| コンテスト | |
| ユーザー | 
                             ixmel
                         | 
                    
| 提出日時 | 2017-03-31 17:44:43 | 
| 言語 | Python3  (3.13.1 + numpy 2.2.1 + scipy 1.14.1)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 394 bytes | 
| コンパイル時間 | 79 ms | 
| コンパイル使用メモリ | 12,672 KB | 
| 実行使用メモリ | 10,752 KB | 
| 最終ジャッジ日時 | 2024-06-27 13:42:59 | 
| 合計ジャッジ時間 | 2,629 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge2 / judge1 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 WA * 1 | 
| other | AC * 36 WA * 7 | 
ソースコード
sa=input()
n=int(input())
sb=input()
ca,cb=0,0
for i in range(3):
	if sa[i]=='o':ca+=1
	if sb[i]=='o':cb+=1
if ca!=cb:
	print("FAILURE")
else:
	if n>=2:
		print("FAILURE")
	elif n==0:
		if sa==sb:print("SUCCESS")
		else:	print("FAILURE")
	else:
		if sa[0]==sb[1] and sa[1]==sb[0] and sa[2]==sb[2] or sa[0]==sb[0] and sa[1]==sb[2] and sa[2]==sb[1]:
			print("FAILURE")
		else:print("SUCCESS")
		
            
            
            
        
            
ixmel