应用经验

文本操作:

fid = fopen("name.txt", 'w'); %w写 r读

fgetl(fid) % 获取文本一行

fprintf(fid, ' ');

* source = importdata('name.txt'); %导入txt文件

source{1} % cell操作{}

strfind(str1, str2) % str2是否是str1的一部分,返回下标

世上无难事,只要肯登攀。
原文地址:https://www.cnblogs.com/littlehoom/p/3541955.html