Форум сайта python.su
Create a simple editor application which can read text file and output everything to the screen,
you also have such functionalities like: Open File, Save As, Replace Function:
****************************
* 1 – Open File
* 2 – Save As
* 3 – Replace
* 4 – Close
* Enter your choice: 1
****************************
Write name of file: input.txt
The single most important skill for a computer scientist is
problem solving. Problem solving means the ability to
formulate problems, think creatively about solutions, and
express a solution clearly and accurately. As it turns out,
the process of learning to program is an excellent
opportunity to practice problem solving skills. That’s why
this chapter is called, “The way of the program.”
****************************
* 1 – Open File
* 2 – Save As
* 3 – Replace
* 4 – Close
* Enter your choice: 3
****************************
Write the word you want to replace:
problem
Write on which word you want to replace it:
task
Changed successfully! 3 changes have been made.
The single most important skill for a computer scientist is
task solving. Task solving means the ability to formulate
problems, think creatively about solutions, and express a
solution clearly and accurately. As it turns out, the
process of learning to program is an excellent opportunity
to practice task solving skills. That’s why this chapter is
called, “The way of the program.”
****************************
* 1 – Open File
* 2 – Save As
* 3 – Replace
* 4 – Close
* Enter your choice: 2
****************************
Write name of file: new.txt
Saved successfully!
****************************
* 1 – Open File
* 2 – Save As
* 3 – Replace
* 4 – Close
* Enter your choice: 4
****************************
Bye!
Офлайн