How to read several Json arrays from input and convert them to Java array or List
I'm receiving an input of one or more Json arrays like [{"operation":"buy", "unit-cost":10.00, "quantity": 10000}, {"operation":"sell", "unit-cost":20.00, "quantity": 5000}] [{"operation":"buy", "unit-cost":20.00, "quantity": 10000}, {"operation":"sell", "unit-cost":10.00, "quantity": 5000}] I tried to read the array using JSON-Java in this way: JSONArray array…