Unformatted text preview: The name of your text % file should be "Changed_Summary.txt". You may assume no fields in the % structure array are empty. Do not use the 't' option with fopen. Be % sure that you follow our examples exactly- adding excessive whitespace % (spaces, tabs, newline characters) or getting case wrong will result in % a loss of credit. % Changed_Summary.txt should have a line of text for every structure in % the structure array, and should read like so: % Line # should be changed to "<some text>" %usage: changeSummary(st) fh = fopen('Changed_Summary.txt','w'); %opens the file and allows you to write into it for x = 1:length(st) %initial condition fprintf(fh,'Line %d should be changed to "%s"\n',st(x).linenum,st(x).changeto); %prints out the desired lines and their numbers end fclose(fh); %closes the file end...
View Full Document
This note was uploaded on 10/21/2010 for the course CS 1371 taught by Professor Stallworth during the Spring '08 term at Georgia Tech.
- Spring '08