strstr and arrays

I have to create a character array literal with a poiner that points to the beginning of the array, and use the pointer to modify the elements of the array.
To construct the example, first I wanted to explore the use functions strcpy and strstr. strcpy works but not strstr (strstr works with strings). Would anyone be able to suggest alternative function arrays please?
CODE:
char phrase1[] = {"phrase"};
char phrase2[] = {"Second phrase"};
char phraseA[128];
char *phraseB[128];
strcpy(phraseA, phrase2);
phraseB = strstr(phrase2,phrase1);

for the last line the error message is
E2277 Lvalue required

Many thanks
1
2
3
4
if (const char *p = strstr(phrase2, phrase1))
    std::cout << "found a match" << std::endl;
else
    std::cout << "no match" << std::endl;
Thank you to kbw for the contribution. With the correction included below the code works.

CODE:
char phrase1[] = {"phrase"};
char phrase2[] = {"Second phrase"};
char phraseA[128];
char *phraseB; //------------------------------------- used instead of ----- char *phraseB[128];
strcpy(phraseA, phrase2);
phraseB = strstr(phrase2,phrase1);

if (const char *p = strstr(phrase2, phrase1))
std::cout << "found a match" << std::endl;
else
std::cout << "no match" << std::endl;
Topic archived. No new replies allowed.