in reply to How do read the varibles from a files and do some calculation

File A:
Product Price
AAA|10
BBB|20
CCC|30
DDD|40
more

File B:
Group Name: Small
Junk: lll
Product Name:
AAA
BBB
Group Name: Big
Junk: ggg
Product Name:
AAA
CCC
DDD
more<bg> I need to print out:<br Group Small:
AAA 10
BBB 20
Total 20
Group Big:
AAA 10
CCC 30
DDD 40
Total 80 Thanks!

  • Comment on How to read 2 files and do the calculations