This is probably a dumb question but I am still learning so here goes....
I have a requirement to concatenate two elements of an array.

For example:
Qt Code:
  1. array[0] = "f";
  2. array[1] = "e";
  3. newarray[0] = "0x"+array[0]+array[1]
To copy to clipboard, switch view to plain text mode 
so the result would be "0xfe"

I have tried
Qt Code:
  1. char result[10];
  2. char buffer[10];
  3. sprintf( result[0] , "0x%c%c", (unsigned int) buffer[0], (unsigned int) buffer[1]);
To copy to clipboard, switch view to plain text mode 
which compiled but gave a segmentation error when run.

Any thoughts or suggestions would be greatly appreciated.

Thanks, B1.