Update Parser.java

Updated with SimpleDateFormat to validate dates input