Matlab grader problem error
4 次查看(过去 30 天)
显示 更早的评论
Could someone tell me the mistake I'm making?
2 个评论
回答(2 个)
Sameer Pujari
2021-7-19
try this
fileID = fopen('AwesomeFile.txt','w');
fprintf(fileID,'Matlab is awesome!');
fclose(fileID);
Cris LaPierre
2021-7-19
Follow the advice in the problem description - review the documentation page for fprintf. Your code is not writing anything into the file.
2 个评论
Cris LaPierre
2021-7-19
It's printing it to the screen. It is not, however, writing it to the file 'AwesomeFile.txt'.
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!