subject

What is the output of the following segment of C code: void flipAC(char * x, char l);
int main () {
char * text;
text="This is some sample text.";
flipAC(text, 'e');
printf("%s", text);
return 0;
}
void flipAC(char * x, char l) {
int length=strlen(x);
char temp;
char *e = &x[length-1];
char *p = strchr(x, l) + 1;
while (e != p) {
temp = *p;
*p = *e;
*e = temp;
p++;
e--;
}
}
a) This is somE samplE tExt.
b) .txet elpmas emos si sihT
c) This is some. txet elpmas
d) mos si sihTe sample text.

ansver
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 23.06.2019 06:30, scoutbuffy2512
On early television stations, what typically filled the screen from around 11pm until 6am? test dummies test patterns tests testing colors
Answers: 1
image
Computers and Technology, 23.06.2019 17:00, quanharris2k19
The camera still is bad even with the new iphone xr and especially in low light it is even worst because you can see the pixels more if its in low light. if all you apple customers want apple to fix this then lets fill there feedback with complaints about the
Answers: 1
image
Computers and Technology, 24.06.2019 17:30, bxbykay1
Looking at the electroscope, describe how you can cause the two leaves at the bottom to repel each other and stay that way
Answers: 3
image
Computers and Technology, 25.06.2019 02:30, Nismo3501037
What are the charges for invasion of privacy on computers
Answers: 1
You know the right answer?
What is the output of the following segment of C code: void flipAC(char * x, char l);
int ma...

Questions in other subjects:

Konu
Biology, 05.02.2020 12:48