The number of rows can be obtained by the file_lines function;
The number of columns can be read from the first line of the file in the form of a string, and then the string is segmented by strsplit function to judge the number of elements after segmentation.
Ha ha! I hope it helps you!