I
int
i have 2 hashes, %newer and %older. %newer is an update of the
data in %older. i would like to know:
1) which key, value pairs are in %newer but not %older
2) which key, value pairs are in %older but not %newer
3) which keys have different values in %older and %newer
4) which values have different keys in %older and %newer
wrote some code, it is messy, it is over 30 lines long lots
of foreach, if, else, blocks and it seems to have a problem
with case 4). looking for a perl idiomatic solution.
any suggestions appreciated.
data in %older. i would like to know:
1) which key, value pairs are in %newer but not %older
2) which key, value pairs are in %older but not %newer
3) which keys have different values in %older and %newer
4) which values have different keys in %older and %newer
wrote some code, it is messy, it is over 30 lines long lots
of foreach, if, else, blocks and it seems to have a problem
with case 4). looking for a perl idiomatic solution.
any suggestions appreciated.