Mathieu Bouchard <matju / cam.org> writes:

> > > If aFile = File.open("myfile.txt") then why is the syntax for finding out
> > > the file size
> > > 	File.size(aFile) instead of aFile.size?
> > The class method is there because you don't have to open a file to
> > determine it's size. In fact, you can find the size of files which you 
> > don't have permission to open.
> 
> You mean File.stat(name).size right? File.size(name) is pretty much
> useless except for inciting users to ask for File#size. 

I must be missing something:

   File.size("/etc/passwd")		# => 2271



Dave