Realized I can shorten python because wc can count the output
./cache1d | wc