Nov-18-2018, 08:05 AM
hello all ...
this is my code :
this is my code :
#qassam = raw_input() def loop(): for i in range(12): qan = "Key.f{}".format(i+1) print qan.split() ''' if qassam in qan: print "yes" else: print "no" ''' loop()output :
Output:['Key.f1']
['Key.f2']
['Key.f3']
['Key.f4']
['Key.f5']
['Key.f6']
['Key.f7']
['Key.f8']
['Key.f9']
['Key.f10']
['Key.f11']
['Key.f12']
i need to convert them to one list like [ 'Key.f1' , 'Key.f2' , 'Key.f3' ....ect ]