📜  python长度检查器填充 - Python代码示例

📅  最后修改于: 2022-03-11 14:47:18.339000             🧑  作者: Mango

代码示例1
# select the right rows to avoid wasting time operating on longer strings
shorter = df.Random.str.len() < 9
longer = ~shorter
df.Random[shorter] = df.Random[shorter].str.zfill(9)
df.Random[longer] = df.Random[longer].str.zfill(20)