Getting the Size of a File : size « File Directory « Ruby






Getting the Size of a File


puts File.size("text.txt")

 

Related examples in the same category

1.find out if a file has a length of zero (0) with zero?:
2.Get its size in bytes with size? or size:
3.Get file size?