+ Start a Discussion
Vivek NayakVivek Nayak 

generatestringarray

HI Carolina,

What is wrong with below code:
Public class StringArrayTest {

   public static list<string> generateStringArray(integer n){
    list<string> mylist=new list<string>();
    for(integer i=0; i<n; i++){
            mylist.add('Test ' + i);
     System.debug(mylist[i]);
    }
   return mylist;     
}
}

I have referred all your replies and post but silll getting error. Please help.
Thanks,
Vivek
Steven NsubugaSteven Nsubuga
What error are you getting ?