Using Raku (formerly known as Perl_6)
perl6 -MText::CSV -e 'my @a = csv( in => $*IN ); my $date = Date.today; \
@a>>.[2] = @a.map: *.[2].subst(/ (\d**2) \/ (\d**2) \/ (\d**4) /, {"$2-$0-$1"} ).Date; \
@a>>.[3] = @a.map: (($date - *.[2])/365.2425).floor; \
csv( in => @a, out => $*OUT );' < file.txt
Sample Input (file.txt):
bob,wag,06/13/1958
ashley,hay,01/23/1983
evan,bert,09/11/1972
maggie,simpson,05/09/2021
lisa,simpson,05/09/2014
bart,simpson,05/09/2012
Sample Output:
bob,wag,1958-06-13,63
ashley,hay,1983-01-23,39
evan,bert,1972-09-11,49
maggie,simpson,2021-05-09,1
lisa,simpson,2014-05-09,8
bart,simpson,2012-05-09,10
The code above returns ISO 8601 dates, and uses ISO 8601 dates to compute years (floored). Briefly, the .csv file is read in and parsed by the csv(…) function, made available by loading the Text::CSV module at the command line. The data is read into array @a, and today's date is recorded as $date.
In the second line of code, subst is used to analyze the third column and return the date-of-birth in yyyy-mm-dd format, which is then converted to an ISO 8601 date by calling .Date on that string. In the third line of code, each ISO 8601 date-of-birth is subtracted from $date today's date, floored, and returned as an extra column. In the last line of code, valid .csv is output.
If mm/dd/yyyy dates are required in the output (same as input but NOT ISO 8601), then reformat the ISO 8601 Date with the following command, just before the csv(in => @a, out => $*OUT) last command:
@a>>.[2] = @a.map: *.[2].mm-dd-yyyy("/");
NOTE: "age-at-date" column is only approximate. The ISO 8601 dates when subtracted will return accurate days, but these are inaccurately converted to years by dividing by 365.2425 days/year and flooring.
[The right way to calculate "age-at-date" is to calculate the number of leap-days a person has lived, e.g. using Raku's is-leap-year function. It's not clear any answer yet posted has accurately addressed this issue--including mine].
https://en.wikipedia.org/wiki/ISO_8601
https://docs.raku.org/language/temporal#index-entry-Date_and_time_functions
https://raku.org