CPSC120A
Fundamentals of Computer Science I


page-title: Post-lab 17 page-subtitle: Traversal and Slicing

A palindrome is text that is the same forward and backward. In this activity you will demonstrate your knowledge of string traversal by writing a function that determines if a word is a palindrome.

Details

Create a function called is_palindrome(text) in a file called palindrome.py. The function should return True if the input text is a palindrome and False otherwise.

Make sure your code follows the course's code conventions.

Sample Test Cases

Function Parameters Expected Output
'radar' True
'racecar' True
'race car' False
'Hannah' False

Submission

Submit your program as a .py file on the course Inquire page before class on Friday October 10th.