简体   繁体   中英

Python : how to convert max int64 number to float?

Is there a way to convert max int64 number to float number?

I have a max int64 number 9223372036854775807 I want to convert this to float or double. How can I do it in python?

I am developing an automated trading system using a well known broker's API. API sent that number as a response to one of my requests.

尝试这个 !

a = float(9223372036854775807)
import sys
print float(sys.maxint)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM