フィルターのクリア

How can i read a text file?

1 回表示 (過去 30 日間)
Sanjeeb Behera
Sanjeeb Behera 2016 年 9 月 15 日
コメント済み: Sanjeeb Behera 2016 年 9 月 15 日
Hi I am using rsa encryption of text message. During read of a message I want to read a text file? How can I read? Can u tell me? Here my code is
m=input('\nEnter the message: ','s');
  2 件のコメント
per isakson
per isakson 2016 年 9 月 15 日
Sanjeeb Behera
Sanjeeb Behera 2016 年 9 月 15 日
But in above code same program has been written. I want to read the text file where more than thousand characters are written instead of a single text message.

サインインしてコメントする。

回答 (1 件)

KSSV
KSSV 2016 年 9 月 15 日
To read a textfile there are multiple options available.
doc load, importdata, textscan etc.,
  2 件のコメント
Sanjeeb Behera
Sanjeeb Behera 2016 年 9 月 15 日
Thank u for ur ans.
can u show me code?
Walter Roberson
Walter Roberson 2016 年 9 月 15 日
ContentOfFile = fileread('NameOfTheFileGoesHere.txt');

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeData Import and Export についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by