Write a program to delete a specified line in textile.should execute as ./a.out <linenumber> <filename> | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
- 3

Write a program to delete a specified line in textile.should execute as ./a.out <linenumber> <filename>

In Linux OS program should be in command line.

22nd Oct 2020, 5:29 PM
SAMARASIMHA REDDY
SAMARASIMHA REDDY - avatar
1 Answer
+ 2
I think it will be required to enter the file name as user input stored in array of char but the use of argv is also required to check if user will give filename and line number as command line argument .the code will be executed as this example: ./a.out file 6
22nd Oct 2020, 5:44 PM
HBhZ_C
HBhZ_C - avatar