2015-11-18 06:14:39 +00:00
|
|
|
@load "filefuncs"
|
2016-12-05 22:15:40 +01:00
|
|
|
function filesize(name ,fd) {
|
|
|
|
|
if ( stat(name, fd) == -1)
|
|
|
|
|
return -1 # doesn't exist
|
|
|
|
|
else
|
|
|
|
|
return fd["size"]
|
2015-11-18 06:14:39 +00:00
|
|
|
}
|
2016-12-05 22:15:40 +01:00
|
|
|
BEGIN {
|
|
|
|
|
print filesize("input.txt")
|
|
|
|
|
print filesize("/input.txt")
|
2015-11-18 06:14:39 +00:00
|
|
|
}
|