Let\'s assume I have the following class:
class Transaction{ Float amount; String Id; }
Now I\'d like to implement a function: