Skip to main content
9 events
when toggle format what by license comment
May 2, 2019 at 10:17 comment added xzczd @ABCDEMMM str = OpenRead["test.txt"]; read@str. Notice OpenRead will create a InputStream[…], just like StringToStream. Once again, please carefully check the documents of all the functions that you don't understand. (Including those under the Details section. ) Don't guess the usage of built-in functions blindly.
May 2, 2019 at 9:50 comment added ABCDEMMM after str = OpenRead["test.txt"] , then StringToStream@str; then read@str ?
May 2, 2019 at 3:49 comment added xzczd @ABCDEMMM It should be read@str. If you still don't understand, remove all the ; and observe those outputs, and think about what input should be used for read, and finally, don't forget to check the document by pressing F1.
May 1, 2019 at 17:44 comment added ABCDEMMM thanks! str = OpenRead["test.txt"] ;string = "str"; this method doesnot work!
Nov 24, 2018 at 7:21 comment added xzczd @ABCDEMMM As mentioned above, please check the document of OpenRead.
Nov 24, 2018 at 1:07 comment added ABCDEMMM "string = "xxx.txt""???
Nov 24, 2018 at 1:02 comment added ABCDEMMM thanks a lot! however, "string = " this method can not be used for very large data (more than 5000 lines), can we use txt or other files to do this work?
Nov 20, 2018 at 14:13 vote accept ABCDEMMM
Nov 20, 2018 at 13:18 history answered xzczd CC BY-SA 4.0