結果
| 問題 | No.825 賢いお買い物 | 
| コンテスト | |
| ユーザー |  motor_radial | 
| 提出日時 | 2019-08-23 18:31:38 | 
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 32 ms / 2,000 ms | 
| コード長 | 297 bytes | 
| コンパイル時間 | 93 ms | 
| コンパイル使用メモリ | 12,416 KB | 
| 実行使用メモリ | 10,752 KB | 
| 最終ジャッジ日時 | 2024-10-13 14:33:30 | 
| 合計ジャッジ時間 | 1,530 ms | 
| ジャッジサーバーID (参考情報) | judge5 / judge3 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 19 | 
ソースコード
A,B,C=map(int,input().split())
num_ans=[]
for i in range(-10,A+1):
    for j in range(-10,B+1):
        if ((A-i)+(B-j))==C:
            num_ans.append([i,j])
ans=[]
for i,j in num_ans:
    if (i+10*j)>0:
        ans.append(i+j*10)
if len(ans)==0:
    print("Impossible")
else:
    print(min(ans))
            
            
            
        