faqts : Computers : Programming : Languages : Perl : Common Problems : File Handling

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

58 of 63 people (92%) answered Yes
Recently 9 of 10 people (90%) answered Yes

Entry

How do I get the size of a file?

Jun 16th, 2001 07:02
Per M Knutsen,


Use the -s operator to return filesize in bytes:
$fileSize = -s $fileName;