Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python
- # -*- coding: utf-8 -*-
- def removeBigValues(tup):
- result = []
- for i in list(tup):
- result.append(-1 if i > 100 else i)
- tup = tuple(result)
- return tup
- # Tests
- testTuple = (1,5,199,544)
- print(removeBigValues(testTuple))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement