note
cdarke
You might have issues using <code>wc -l</code> on Windows, unless you have installed it from somewhere like GNU. However it is easy to implement your own in Perl.<br>Based on [BrowserUk]'s ideas:<code>
use strict;
use warnings;
my $t=time;
# $n = `attrib /s c:\\* | wc -l`;
open (my $pipe, '-|', 'attrib /s c:\\*') or die "attrib: $!";
my $n = 0;
while (<$pipe>) { $n++ }
close $pipe;
printf "$n : %.f\n", time()-$t;
</code>
Gives: <code>380366 : 135</code> on a used space of 297GB.
946545
946567