1月 24, 2018 for x in range(10): for x in range(10): print(x) if x==0: for x in range(10): print(x) else: print(x) 閱讀完整內容
loop python crash thing 1月 24, 2018 for x in range(1000000000000000000000000000000000000000000000000000000): for x in range(10): print(x) 閱讀完整內容
1月 24, 2018 used="hi" user=input("type a word ") use=1 while used.isalnum(): print("hello") use += 1 if use<=2: print("hi") elif use>=10: print("hello") else: break copyright@timotimo 閱讀完整內容
1月 24, 2018 # The activater of the functions testFunction( " Hello Functions! " ) print ( " Daniel's loves " , getFood()) start( 10 ) copyright@danielshe 閱讀完整內容
1月 24, 2018 # Functions def testFunction ( s ): print (s) # Return def getFood (): return " ice cream " copyright@danielshe 閱讀完整內容
1月 24, 2018 def start(count): i = 0 a = 0 b = 1 while(i < count): sum = a + b print(str(sum)) a = b b = sum i += 1 start(count) copyright@danielshe 閱讀完整內容
1月 24, 2018 # [ ] review the code, run, fix the Logic error count = 1 counted=100000 # loop 5 times while count < counted: print(count , "x", str(count), "=", str(count*count)) count += 1 copyright@danielshe 閱讀完整內容