-->
当前位置:首页 > 题库

PROGRAMMING:Enter the name of the file, open the file and output the contents of the file to the screen.

Luz5年前 (2021-05-10)题库403
Write a program, when the user input file name does not exist, you can re-enter, until you enter a correct file name, open the file and output the contents of the file to the screen.
###Input format:
Enter a valid file name.
###Output format:
Output opens the file and displays its contents to the screen.
###Input example:
```in
Please enter the file path and file name: d://1.txt
```
###Output example:
```out
Please enter the file path and file name: d://1.txt
You have successfully opened a file
```






answer:If there is no answer, please comment