Daily questions 2019.9.17

Coding = UTF-8 # 
"" "
Monkey eating peach issues: the monkey off his first day of a number of peach, half eaten immediately, not addiction, but also eat a morning in turn eaten by the remaining peach half, then
eat one. eat when you want to eat before the rest of the day every morning after half a zero. to day 10 in the morning, see the next only a peach. seeking first day were picked number .
program analysis: the method of reverse thinking taken from the forward inference.
"" "
X2 =. 1
for Day in Range (. 9, 0, -1):
X1 = (. 1 + X2) * 2
X2 = X1
Print (" {0} of {1} days remaining peach ".format (day, X1))
Print (" total "+ str (x1) +" peach ")

# run screenshot:

 

 # Beginner Python if insufficient exhibitions

Guess you like

Origin www.cnblogs.com/walxt/p/11537204.html