forked from tdwojak/Python2017
labs04 z1
This commit is contained in:
parent
7a1a975bdc
commit
b5a3890c93
@ -1,3 +1,13 @@
|
|||||||
#!/usr/bin/env python2
|
#!/usr/bin/env python2
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
#e
|
||||||
|
def is_numeric(InputList):
|
||||||
|
OutputLits = []
|
||||||
|
for i in range(len(InputList)):
|
||||||
|
t = InputList[i]
|
||||||
|
OutputLits.append(isinstance(t,(int, float)))
|
||||||
|
#print(isinstance(x,(int, float)))
|
||||||
|
return OutputLits
|
||||||
|
|
||||||
|
x = is_numeric([1,2.3,'safd',2.2,[1,2]])
|
||||||
|
print(x)
|
Loading…
Reference in New Issue
Block a user