Data computing involving multiple homogeneous datasheets

There are 3 text files Finance.txt , Sales.txt, and Marketing.txt. They are of the same structure and respectively stores the employee data of Finance Department, Sales Department, and Marketing Department. Please compute the total number of male and female employees of these 3 departments and the average age of all employees.

Solution:

A
1
=file@s("Finance.txt").import@t()
2
=file@s("Sales.txt").import@t()
3
=file@s("Marketing.txt").import@t()
4
=A1|A2|A3
5
=A4.count@b(GENDER=="M")
6
=A4.count@b(GENDER=="F")
7
=round(A4.avg(age(BIRTHDAY)),2)

The computations in A5, A6 and A7 are shown below: