Answer:
Code A runs faster than Code B.
Step-by-step explanation:
Values are stored as index based in the ArrayList. If you like to access one element, time complexity will be O(1). However, if you like to access an element in the LinkedList, you need to go through all the elements before that element, time complexity will be O(n).