Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Write a C program. Take info from standard input, tokenize INCOMPLETE CODE #include #include #include #include #define ROWS 20 #define COLUMNS 30 int main(int argc,
Write a C program.
Take info from standard input, tokenize
INCOMPLETE CODE
#include
#define ROWS 20 #define COLUMNS 30
int main(int argc, char *argv[]) { char input_table[ROWS][COLUMNS]; ...... int current_row; printf("Enter name age and wage: "); fgets(input_table[current_row], 30, stdin); // add a while(....) { /* need to 'tokenize' the read in line*/ ......
} /* now display the input_table row by row */ .... ....
return 0; }
The program should use a table-like 2-D array (ie, an array of strings') to record the inputs. use loop to read inputs (from standard in), one input per line, about the user information in the form of name age wage, where age is an integer literal, and wage is a floating point literal with 1 decimal number. See sample input below store each input string into the current available 'row' of the 2D array, starting from the row 0 create a modified string of the input, and store it in the next row of the 2D array. In the modified version of input, a letters in name are capitalized, age becomes age 10 and wage has 50% increases and is formatted with 2 digits after decimal point continue reading input, until a name xxx is entered after reading all the inputs, output the 2-D array row by row, displaying each original input followed by the modified version of the input. display the current date and time and program name before generating the output, using predefined marcos such as TIMEStep 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