/* package whatever; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
	public static void main (String[] args) throws java.lang.Exception
	{
	   String[] words = {"leet","code"}; 
	   char x = 'e';
	   System.out.println(findWordsContaining(words,x));
	   
	}
	
	   static List<Integer> findWordsContaining(String[] words, char x) {
        List<Integer> list = new ArrayList<>();
     
    	int n = words.length;

        for(int i=0;i<n;i++){
            if(check(words[i],x)){
                list.add(i);
            }
        }

        return list;
    }


    static boolean check(String word,char target){
        
        for(int i=0;i<word.length();i++){
            
            char ch = word.charAt(i);
            
             if(ch == target){
              return true;
            }
        }
        return false;
    }
}