function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Javier Jove 7Javier Jove 7 

Problem with Getting Started with Apex help me

User-added image
User-added image
User-added image
Best Answer chosen by Javier Jove 7
Oscar Alejandro Garcia BenitezOscar Alejandro Garcia Benitez

Que tal Javier.

Checando veo que generas otra Clase llamada generateStringArray, y lo que tu ocupas es que este metodo este dentro de la clase StringArrayTest, gran parte del codigo que tienes en dicha clase es correcto, en parte te hizo falta utilizar la variable 'n' y tu lo delimitaste con '6'

Te dejo como a mi si me funciono:

 

public class StringArrayTest {

    public static List<string> generateStringArray(Integer n)
    {
        List<String> myArray = new List<String>();
        for(Integer i=0;i<n;i++)
        {
            myArray.add('Test '+i);
            System.debug(myArray[i]);
        }
        return myArray;
    }
    
}