How to convert text file to string?
69 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Maaz Madha
am 8 Dez. 2021
Beantwortet: Abolfazl Chaman Motlagh
am 8 Dez. 2021
I have a text file (containing text and not numbers) and I would like to convert it to a string so that it becomes like. I have attached an example file just as a reference
str='ExampleQuestion'
0 Kommentare
Akzeptierte Antwort
Abolfazl Chaman Motlagh
am 8 Dez. 2021
use fscan or fread
F = fopen('Untitled.txt');
Text = fscanf(F,'%c')
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Text Files finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!