How can I add strings to an array?

I want to add a ",4" to my array and I don-t know how.

CODE:

char array[]={"1,2,3"};

void setup() {
Serial.begin(9600);
}

void loop() {

// array[].add(",4"); ?????????
Serial.println(array);
delay(1000);

  1. Please use code tags, see "How to use the forum"
  2. make array large enough to start with (aka at least 8 here)
  3. use strncat() to concatenate the new string to the old.

If you want a quick answer or some hints and cannot wait for the forum to respond, take the title of your post, add Arduino in front of it and submit it as a Google search, such as;

Arduino How can I add strings to an array?