Let's apply the State Machine pattern for parsing lines with the specific pattern using S4 Class feature from R.
PROBLEM ENUNCIATION
We need to parse a file where each line provides information about a person, using a delimiter (";"), but some information provided is optional, and instea...