Matlab grader problem error

4 次查看(过去 30 天)
Could someone tell me the mistake I'm making?

回答(2 个)

Sameer Pujari
Sameer Pujari 2021-7-19
try this
fileID = fopen('AwesomeFile.txt','w');
fprintf(fileID,'Matlab is awesome!');
fclose(fileID);

Cris LaPierre
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 个评论
Cristian Segura Bidermann
Yes, if the code writes what is required
Cris LaPierre
Cris LaPierre 2021-7-19
It's printing it to the screen. It is not, however, writing it to the file 'AwesomeFile.txt'.

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Write C Functions Callable from MATLAB (MEX Files) 的更多信息

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by