Apr-16-2020, 01:59 PM
(Apr-15-2020, 07:58 PM)Larz60+ Wrote:Quote:Hi everyone!I am curious about if i can write this code using for loopYes
Quote:if yes could you give me some hints?make an attempt, and show where you need help -- hint
while ...: ...
n = int(sys.argv[1]) p = 1 b = [] for i in range(2,n+1,2): b += [i] a = b[-1]/2 print(a)