+ 1
Why do I get strange characters that are not in file?
When I run this on my pc, I get "I am a file scsc"(without quotes) where sc is a strange character. (Such as @,#, etc. (Some sc are not even on keyboard). When I use frm_file[20] , it prints "I am a file" (correct output). Also, when I use frm_file[100] or 1000 or very larger values, I get correct output. Why?? https://code.sololearn.com/cH9aceCVpk0r/?ref=app
4 Answers
+ 1
Ok ~ swim ~ . I'll try this.
Thanks
0
Maybe Because in your file you have data more than 15 characters and you defined file size with 15 character.
0
đ
°đ
š - ÉŞ'á´ á´ĘÉŞá´ÉŞÉ´á´ĘĘĘ É˘á´á´á´
! . The file has 11 characters + 1( null character)