Write a program to check give word is a palindrom or not, Computer Engineering

Assignment Help:

Write a program to check whether a given word is a palindrome or not?

# include

# include

void main()

{

char word[10];

int length=0,mid,count=0;

clrscr();

printf("\tEnter the Word :\> ");

gets(word); printf("\n\n\n"); while(word[count]!='\0')

{

length++;

count++;

}

mid = length/2;

for(count=0;count<=mid;count++)

{

if (word[count]!=word[(length-1)-count])

{

printf("\t\n\nGiven String is Not a Palindrome");

getch();

exit();

}

}

printf("\t\n\nGiven String is a Palindrome");

getch();

}

 


Related Discussions:- Write a program to check give word is a palindrom or not

User interface (ui), Design a easy (text-based/ graphical) UI for  your pr...

Design a easy (text-based/ graphical) UI for  your program.  The user should be encouraged for  parameter values for  the particular protocol simulation. For  example, the user sho

Anu, write a program to find the area under the curve y=f(x) between x=a an...

write a program to find the area under the curve y=f(x) between x=a and y=b integrate y=f(x) between the limits of a and b. the area under a curve between two points can be found b

What is an "on input filed" statements, What is an "on input filed" stateme...

What is an "on input filed" statements? ON INPUT The ABAP/4 module is known as only if a field having the Value other than the initial Value. This initial Value is explain

What are language processor development tools, What are Language Processor ...

What are Language Processor Development Tools (LPDTs)? LPDT that is Language processor development tools focuses upon generation of the analysis phase of language processors. T

When should the method invokelater() be used, This method is used to make s...

This method is used to make sure that Swing components are updated by the event-dispatching thread.

State any three properties of the neutrons, Q. State any three properties o...

Q. State any three properties of the neutrons. (i) A Neutrons are the constituent particles of all nuclei except hydrogen. (ii) As they are neutral particles they aren't de

Define point-to-point communication, Q. Define Point-to-point Communication...

Q. Define Point-to-point Communication? The simplest form of message is a point to point communication. A message is sent from the transmitting processor to a receiving process

Explain various steps for analysing an algorithm, Explain various steps for...

Explain various steps for analysing an algorithm.  The several steps involved in analysis of an algorithm are: 1. For any algorithm, the first step should be to show that it

Define windows authentication, Windows Authentication This provider uti...

Windows Authentication This provider utilizes the authentication capabilities of IIS. After IIS completes its authentication, ASP.NET uses the authenticated identity's token to

Show example of copy command, Q. Show example of COPY command? This COP...

Q. Show example of COPY command? This COPY command copies the REPORT file from the drive C to the disk in drive A. after copying the file in drive A, it will name the new file

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd