get just the integer from wc in bash

Most simple answer ever:

wc < filename 

Just:

wc -l < file_name

will do the job. But this output includes prefixed whitespace as wc right-aligns the number.