Thompson's Construction Algorithm for Regular Expression