feat: add for loop, python version

This commit is contained in:
2025-09-03 00:31:22 +08:00
parent b8120d6768
commit 71ad0966bc
2 changed files with 19 additions and 0 deletions

11
for_loop.py Normal file
View File

@@ -0,0 +1,11 @@
#!/usr/bin/env python3
if __name__ == "__main__":
strings = ["str1", "str2", "str3"]
print("length:", len(strings))
strings.append("str4")
strings.append("str5")
print("length:", len(strings))
strings.pop()
for s in strings:
print(s)