-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathprogram201.c
More file actions
52 lines (39 loc) · 702 Bytes
/
Copy pathprogram201.c
File metadata and controls
52 lines (39 loc) · 702 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
#include<stdio.h>
#include<stdbool.h>
bool ChekPallindrom(char *str)
{
char *start = NULL;
char *End = NULL;
char temp = '\0';
bool bflag = true;
start = str;
End = str;
while(*str != '\0')
{
str++;
}
str--;
End = str;
while(start < End)
{
if(*start != *End)
{
bflag = false;
break;
}
start++;
End--;
}
}
int main()
{
bool bRet = 0;
char cValue = '\0';
char Arr[50] = {'\0'};
printf("Enter String :\n");
scanf("%[^'\n']s",Arr);
strrevX(Arr);
printf("String after reversal %s\n",Arr);
return 0;
}
// Order of O(n/2)