zl程序教程

您现在的位置是:首页 >  后端

当前栏目

python 字符串和整型组合,while 循环

Python循环 字符串 组合 while 整型
2023-09-14 09:09:50 时间

1. python 字符串拼接和循环

#coding:utf-8
user = "ftp"
num = 1
while (num < 10):
    userS = user + str(num)
    num = num +1
    print userS

参考:
1.Python While 循环语句