Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def only_numeric(a):
- n = []
- for i in a:
- if type(i) == list:
- for j in i:
- if type(j) == int or type(j) == float:
- n.append(j)
- else:
- if type(i) == int or type(i) == float:
- n.append(i)
- return n
Advertisement
Add Comment
Please, Sign In to add comment