Skip to content

Commit 2f7edbc

Browse files
authored
Create Bon_Appetit.py
1 parent 0c9a370 commit 2f7edbc

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

Bon_Appetit.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# Enter your code here. Read input from STDIN. Print output to STDOUT
2+
3+
n, k = map(int, raw_input().split())
4+
A = map(int, raw_input().split())
5+
b = int(raw_input())
6+
7+
tot = sum(A) - A[k]
8+
if 2*b == tot: print "Bon Appetit"
9+
else: print b - tot / 2

0 commit comments

Comments
 (0)