This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| '''Converts a float to a list of an integer and the amount of decimal places''' | |
| def float_to_custom_notation(fl): | |
| power = 0 | |
| while(not fl.is_integer()): | |
| fl = float(fl) | |
| fl *= 10 | |
| power += 1 | |
| fl = float(fl) | |
| return{int(fl), power} |