Lex program to check whether given string is Palindrome or Not
Problem: Write a Lex program to check whether given string is Palindrome or Not.
Lex is a computer program that generates lexical analyzers and was written by Mike Lesk and Eric Schmidt. Lex reads an input stream specifying the lexical analyzer and outputs source code implementing the lexer in the C programming language.
Description: A string is said to be palindrome if reverse of the string is same as string. For example, “abba” is palindrome, but “abbc” is not palindrome.
Input: Enter a string : naman Output: Given string is Palindrome Input: Enter a string : geeksforgeeks Output: Given string is not Palindrome