Duplicate String : I have a task to find duplicate elements and write a method to return a boolean value.
Code below is what I have for it. 

    import java.util.ArrayList;
    import java.util.List;
    
    public class DuplicateEle {
    	public static void main(String args[]) {
    		String[] arr = { "hello", "hi", "hello", "howru" };
    		DuplicateEle de = new DuplicateEle();
    		for (int i = 0; i < arr.length; i++) {
    			boolean isDup = de.isDuplicate(arr[i]);
    			System.out.println(arr[i]+" is duplicate :" +isDup);
    		}
    	}
    
    	List<String> dList = new ArrayList<String>();
    
    	private boolean isDuplicate(String str) {
    		boolean isDup = false;
    		if (dList.contains(str)) {
    			isDup = true;
    		} else
    			dList.add(str);
    		return isDup;
    	}
    
    }

It works as expected. 
output :

    hello is duplicate :false
    hi is duplicate :false
    hello is duplicate :true
    howru is duplicate :false

I want to find the time complexity for the above code. I am looking into the tutorial for time complexity about how it works. 
http://www.geeksforgeeks.org/analysis-of-algorithms-set-4-analysis-of-loops/

Can someone please give me inputs on the above code and help me understand how time complexity works please ? 

Thank you in advance !
 