小编Dav*_*ave的帖子

Python类型转换

什么是在python中将int's,long's,double's转换为字符串,反之亦然的最佳方法.

我循环遍历列表并将long传递给应该转换为unicode字符串的dict.

我做

for n in l:  
    {'my_key':n[0],'my_other_key':n[1]}
Run Code Online (Sandbox Code Playgroud)

为什么一些最明显的事情如此复杂?

python int types

10
推荐指数
2
解决办法
7万
查看次数

标签 统计

int ×1

python ×1

types ×1