shell scripting Python

 

#!/usr/bin/python3
print("hello, world!")
name = 'Jerry'
print(f"Hello, {name}, welcome back.")
sum = 0
for i in range(1, 101):
    sum += i
print(f"sum = {sum}")

 

或者把

print("hello, world!")
name = 'Jerry'
print(f"Hello, {name}, welcome back.")
sum = 0
for i in range(1, 101):
    sum += i
print(f"sum = {sum}")

保存到hello.py中,shell scripts就变成这样:

#!/usr/bin/python3 hello.py

 

上一篇:Vue源码:虚拟DOM和diff算法


下一篇:Vue原理-diff比对算法