Create ex3.py

function to get records from input file.