Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
bellcode
/
lesson13-1
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
bad360b3
authored
Oct 20, 2024
by
BellCodeEditor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
save project
parent
62806fe7
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
7 deletions
a.py
diy.py
i.py
a.py
0 → 100644
View file @
bad360b3
file
=
open
(
r'C:\Users\cc\Desktop\test.txt'
,
'w'
,
encoding
=
'utf-8'
)
file
.
write
(
'诺'
)
file
.
close
()
file
=
open
(
r'C:\Users\cc\Desktop\test.txt'
,
'r'
,
encoding
=
'utf-8'
)
q
=
file
.
read
()
print
(
q
)
file
.
close
()
file
=
open
(
r'C:\Users\cc\Desktop\test.txt'
,
'r'
,
encoding
=
'utf-8'
)
for
i
in
file
:
if
"诺"
in
i
:
print
(
"诺依"
)
\ No newline at end of file
diy.py
View file @
bad360b3
...
...
@@ -10,3 +10,4 @@ for i in a:
i.py
View file @
bad360b3
d
=
"胡#几天后#计日工#发工资"
s
=
d
.
split
(
'#'
)
print
(
s
)
lll
=
"我 们 都 是 中 国 人"
s
=
lll
.
split
(
' '
)
print
(
s
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment