Write a program (4%) that:Opens a file called MyQualities.txt for writing.Repeatedly …Reads a sentence from the keyboard (using fgets).Checks if the sentences starts with “I am ” (using strstr)If it does, then extracts the substring starting at the 5th character, i.e., the substring containing the quality the person believes they possess. (using strncpy).Concatenates the substring onto a growing string containing all such qualities, with a comma separator (using strncat – the growing string has a maximal length of 1024 characters).Appends the substring to the MyQualities.txt file.Stops looping when a string containing just a “.” is entered (check using strcmp).Outputs the grown string of qualities to the screen.Opens the MyQualities.txt file for readingReads and echo the qualities from the fileDeletes the fileHere’s what a sample run should look like (with the keyboard input shown in italics) … Please enter sentences, . to end.
I am very clever
Most people are not
I am good looking too
I am really good looking
You are ugly
I am confident
The qualities are very clever, good looking too, really good looking, confident.
Confirming the saved qualities …
good looking too
eally good looking confident
Welcome to originalessaywriters.com, our friendly and experienced essay writers are available 24/7 to complete all your assignments. We offer high-quality academic essays written from scratch to guarantee top grades to all students. All our papers are 100% plagiarism-free and come with a plagiarism report, upon request
Tell Us “Write Essay for Me” and Relax!