For each element i in each list perform an operation. Elements can be processed in any order. For example in old java:
List<A> aList;
List<B> bList; // aList is larger than bList
for (int i=0; i<bList.size(), i++) {
aList.get(i).doSomethingWith(bList.get(i));
}
for (int j=i; j<aList.size(), j++) {
aList.get(j).doSomething();
}
Which is the best way to implement this with java.util.stream.Stream so elements can be processed in parallel?