Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Answer in C (This is all the information provided.) e2q1.c - This program will accept two command-line arguments: an input filename an integer T Example
Answer in C (This is all the information provided.)
e2q1.c - This program will accept two command-line arguments:
- an input filename
- an integer T
- Example run command: ./a.out in.txt 4
The program will create two files:
- big.txt contains all tokens from the input file with length greater than or equal to T
- small.txt contains all tokens from the input file with length less than T
- A token is a group of characters surrounded by whitespace.
- Each token should appear on its own line in the output file in order of appearance.
- Assume valid input and that no token will be more than 100 characters.
- If you create your own test input file, make sure to end the file with an empty newline.
- Follow the standard read pattern.
- Close all files.
Example: ./a.out in.txt 4
in.txt (given) big.txt (created) small.txt(created) 5 The sun did not shine. shine. 6 It was too wet to play. play. 7 So we sat in the house house 8 All that cold, cold, wet day that cold, cold, day. 5 The sun did not 6 It was too wet to 7 So we sat in the 8 All wet
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started