Question: I have N numbers in arraylist. To get the `indexOf`, arraylist will have to iterate maximum N times, so complexity is `O(N)`, is that correct?

Answer: 
Yes, that is correct. The order is based off the worst case.
It is true. Best Case is 1 so O(1), Average Case is N/2 so O(N) and Worst Case is N so O(N)