FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
learn-python/create_variable.py at master · wbzdssm/learn-python · GitHub
wbzdssm
/
learn-python
Public
forked from
tanteng/learn-python
Notifications
You must be signed in to change notification settings
Fork
0
Star
0
Code
Pull requests
0
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
learn-python
/
create_variable.py
Copy path
More file actions
More file actions
Latest commit
History
History
History
14 lines (11 loc) · 217 Bytes
Breadcrumbs
learn-python
/
create_variable.py
Copy path
File metadata and controls
14 lines (11 loc) · 217 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
"""
演示Python如何动态创建变量
"""
pages
=
{}
for
page
in
range
(
1
,
50
):
"""
这里想创建变量page1 = 1, page2 = 2, page3 = 3,...
"""
pages
[
page
]
=
page
print
(
pages
[
1
])
print
(
pages
[
2
])
Back
|
FazBrowse Home
|
New Git URL