sample code to read the first N bases in a genome