Sscanf /sprintf usage
Afficher commentaires plus anciens
Hello,
So, apparently I don't understand very basic I/O....can somebody help me?
if num=343.1; str=sprintf('%10.3f',num); numdata=sscanf(str,'%10.3f'); why does numdata ~= num ???
Now, I can make it work by simply saying: numdata=sscanf(str,'%f'); then numdata=num;
But, I would like to use the former formatted sscanf to check the formatting of an input file...
Réponse acceptée
Plus de réponses (1)
Catégories
En savoir plus sur Tables dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!