Write a program to find the number of palindrome words in a given string. For example, given the string "mom dad child", the program should return 2.

AnswerBot
2y

Count the number of palindrome words in a given string.

  • Split the string into words using space as a delimiter.

  • Iterate through each word and check if it is a palindrome.

  • Increment the count if the word ...read more

Help your peers!
Add answer anonymously...
Moolya Software Testing Automation Engineer Interview Questions
Stay ahead in your career. Get AmbitionBox app
qr-code
Trusted by over 1.5 Crore job seekers to find their right fit company
80 L+

Reviews

10L+

Interviews

4 Cr+

Salaries

1.5 Cr+

Users

Contribute to help millions

Made with ❤️ in India. Trademarks belong to their respective owners. All rights reserved © 2025 Info Edge (India) Ltd.

Follow Us
  • Youtube
  • Instagram
  • LinkedIn
  • Facebook
  • Twitter
Hello, Guest
AmbitionBox Employee Choice Awards 2025
Winners announced!
Contribute to help millions!
Write a review
Share interview
Contribute salary
Add office photos
Add office benefits