Putting into practise Stream API and Lambda Expressions
Source: Java 8 in Action Lambdas, streams, and functional-style programming, Raoul-Gabriel Urma, Mario Fusco, and Alan Mycroft
** Excersice : **
-
Find all transactions in the year 2011 and sort them by value (small to high).
-
What are all the unique cities where the traders work?
-
Find all traders from Cambridge and sort them by name.
-
Return a string of all traders’ names sorted alphabetically.
-
Are any traders based in Milan?
-
Print all transactions’ values from the traders living in Cambridge.
-
What’s the highest value of all the transactions?
-
Find the transaction with the smallest value.
** Note: Classes Trader and Transaction can be found on src file **