Others
Assessment
CenterForComputing
ChatGPT
Search
Close
Log in
Register
CenterForComputing
You are here:
CenterForComputing
»
Syllabi
»
CSC121SylF2023
»
CSC121F2023Lab08
»
CSC121F2023Lab08Hint3
Hints to copy a file
20 Jun 2023 - 16:12
|
Version
1
|
UnknownUser
The basic idea:
open one file for reading and the other for writing
while not at the end of file of the input file
read the current line from the input file
write it to the output file
close both files
To change a given line
add a counter to your loop
if it is not the line you want, continue as normal
if it is the line you want, write the change (but don't forget to count this line).
Attachments
($count)
Show options
Search:
Sort by:
Name
Date
Author
Size
Type
Results per page:
6
12
24
48
all
Display hidden:
More actions
Create link(s)
Embed
Download
Hide
Unhide
Move
Delete
0
attachment(s)
Select all
Clear all
Copyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki?
Send feedback
This website is using cookies.
More info
.
That's Fine