SlideShare ist ein Scribd-Unternehmen logo
1 von 1
Downloaden Sie, um offline zu lesen
Check the Challenge 2 practice exercise as a reference Write a function called isPatindrome
which takes a string s and returns a Boolean value (True / False). Tip. You can use the same
strategy as the exercise from Lab 06 where you had a collection of brackets and you checked if
the string was valid. This function should: 1. Check if s is a palindrome (not case sensitive) - If so,
return True - Otherwise, return False Example usage: print (ispalindrome("Anna")) "outputs the
boolean value True print(ispalindrome("Book")) "outputs the boolean value False - A palindrome is
a word, phrase, number or sequence of words that reads the same backward as forward. in our
case, only checking for single word palindromes. Examples: - Anna - Civic - Kayak - Level -
Madam - Mom - Noon - Racecar - Radar - Redder - Refer - Repaper

Weitere ähnliche Inhalte

Mehr von aghsports

Cisconun Tedarik Zinciri Cisconun tedarik zinciri d kayna.pdf
Cisconun Tedarik Zinciri Cisconun tedarik zinciri d kayna.pdfCisconun Tedarik Zinciri Cisconun tedarik zinciri d kayna.pdf
Cisconun Tedarik Zinciri Cisconun tedarik zinciri d kayna.pdfaghsports
 
CISC 341 Computer Architecture You must show your work to.pdf
CISC 341 Computer Architecture  You must show your work to.pdfCISC 341 Computer Architecture  You must show your work to.pdf
CISC 341 Computer Architecture You must show your work to.pdfaghsports
 
Cinematix se vuelve mvil Cinematix Cinema ha revisado reci.pdf
Cinematix se vuelve mvil  Cinematix Cinema ha revisado reci.pdfCinematix se vuelve mvil  Cinematix Cinema ha revisado reci.pdf
Cinematix se vuelve mvil Cinematix Cinema ha revisado reci.pdfaghsports
 
CIGS thinfilm solar modules are potentially competitive wit.pdf
CIGS thinfilm solar modules are potentially competitive wit.pdfCIGS thinfilm solar modules are potentially competitive wit.pdf
CIGS thinfilm solar modules are potentially competitive wit.pdfaghsports
 
Choose the correct statement below A Estimators do not gen.pdf
Choose the correct statement below A Estimators do not gen.pdfChoose the correct statement below A Estimators do not gen.pdf
Choose the correct statement below A Estimators do not gen.pdfaghsports
 
Choose the correct word to complete these descriptions of st.pdf
Choose the correct word to complete these descriptions of st.pdfChoose the correct word to complete these descriptions of st.pdf
Choose the correct word to complete these descriptions of st.pdfaghsports
 
Choose one of these three options A IPC using FIFO B Shar.pdf
Choose one of these three options A IPC using FIFO B Shar.pdfChoose one of these three options A IPC using FIFO B Shar.pdf
Choose one of these three options A IPC using FIFO B Shar.pdfaghsports
 
CHOOSE ONLY ONE OF THE FOLLOWING 7 marks 1 Describe in .pdf
CHOOSE ONLY ONE OF THE FOLLOWING 7 marks 1 Describe in .pdfCHOOSE ONLY ONE OF THE FOLLOWING 7 marks 1 Describe in .pdf
CHOOSE ONLY ONE OF THE FOLLOWING 7 marks 1 Describe in .pdfaghsports
 
Choose the correct answer 1 The method _ is called by the .pdf
Choose the correct answer 1 The method _ is called by the .pdfChoose the correct answer 1 The method _ is called by the .pdf
Choose the correct answer 1 The method _ is called by the .pdfaghsports
 
Choose your own project idea or select one of the following.pdf
Choose your own project idea or select one of the following.pdfChoose your own project idea or select one of the following.pdf
Choose your own project idea or select one of the following.pdfaghsports
 
choose the correct answer 1 Water will flow into the beaker.pdf
choose the correct answer 1 Water will flow into the beaker.pdfchoose the correct answer 1 Water will flow into the beaker.pdf
choose the correct answer 1 Water will flow into the beaker.pdfaghsports
 
Choose the best description of a cDNA library a mixture o.pdf
Choose the best description of a cDNA library a mixture o.pdfChoose the best description of a cDNA library a mixture o.pdf
Choose the best description of a cDNA library a mixture o.pdfaghsports
 
Choose an indicator from The Canadian Environmental Sustaina.pdf
Choose an indicator from The Canadian Environmental Sustaina.pdfChoose an indicator from The Canadian Environmental Sustaina.pdf
Choose an indicator from The Canadian Environmental Sustaina.pdfaghsports
 
Chapter 7 Business and the Environment 1 What is intrins.pdf
Chapter 7  Business and the Environment 1 What is intrins.pdfChapter 7  Business and the Environment 1 What is intrins.pdf
Chapter 7 Business and the Environment 1 What is intrins.pdfaghsports
 
Choose a major country to research Australia Write a repo.pdf
Choose a major country to research Australia Write a repo.pdfChoose a major country to research Australia Write a repo.pdf
Choose a major country to research Australia Write a repo.pdfaghsports
 
Choose an article from US News 2020 Public Health https.pdf
Choose an article from US News 2020 Public Health https.pdfChoose an article from US News 2020 Public Health https.pdf
Choose an article from US News 2020 Public Health https.pdfaghsports
 
Chinas Great FirewallChina has a population of over 14 bil.pdf
Chinas Great FirewallChina has a population of over 14 bil.pdfChinas Great FirewallChina has a population of over 14 bil.pdf
Chinas Great FirewallChina has a population of over 14 bil.pdfaghsports
 
Choose ALL that are TRUEWhich of the following commonly uses.pdf
Choose ALL that are TRUEWhich of the following commonly uses.pdfChoose ALL that are TRUEWhich of the following commonly uses.pdf
Choose ALL that are TRUEWhich of the following commonly uses.pdfaghsports
 
Choose a product or service that you are familiar with some.pdf
Choose a product or service that you are familiar with some.pdfChoose a product or service that you are familiar with some.pdf
Choose a product or service that you are familiar with some.pdfaghsports
 
Chinas GDP expanded at its slowest pace since the mid1970s.pdf
Chinas GDP expanded at its slowest pace since the mid1970s.pdfChinas GDP expanded at its slowest pace since the mid1970s.pdf
Chinas GDP expanded at its slowest pace since the mid1970s.pdfaghsports
 

Mehr von aghsports (20)

Cisconun Tedarik Zinciri Cisconun tedarik zinciri d kayna.pdf
Cisconun Tedarik Zinciri Cisconun tedarik zinciri d kayna.pdfCisconun Tedarik Zinciri Cisconun tedarik zinciri d kayna.pdf
Cisconun Tedarik Zinciri Cisconun tedarik zinciri d kayna.pdf
 
CISC 341 Computer Architecture You must show your work to.pdf
CISC 341 Computer Architecture  You must show your work to.pdfCISC 341 Computer Architecture  You must show your work to.pdf
CISC 341 Computer Architecture You must show your work to.pdf
 
Cinematix se vuelve mvil Cinematix Cinema ha revisado reci.pdf
Cinematix se vuelve mvil  Cinematix Cinema ha revisado reci.pdfCinematix se vuelve mvil  Cinematix Cinema ha revisado reci.pdf
Cinematix se vuelve mvil Cinematix Cinema ha revisado reci.pdf
 
CIGS thinfilm solar modules are potentially competitive wit.pdf
CIGS thinfilm solar modules are potentially competitive wit.pdfCIGS thinfilm solar modules are potentially competitive wit.pdf
CIGS thinfilm solar modules are potentially competitive wit.pdf
 
Choose the correct statement below A Estimators do not gen.pdf
Choose the correct statement below A Estimators do not gen.pdfChoose the correct statement below A Estimators do not gen.pdf
Choose the correct statement below A Estimators do not gen.pdf
 
Choose the correct word to complete these descriptions of st.pdf
Choose the correct word to complete these descriptions of st.pdfChoose the correct word to complete these descriptions of st.pdf
Choose the correct word to complete these descriptions of st.pdf
 
Choose one of these three options A IPC using FIFO B Shar.pdf
Choose one of these three options A IPC using FIFO B Shar.pdfChoose one of these three options A IPC using FIFO B Shar.pdf
Choose one of these three options A IPC using FIFO B Shar.pdf
 
CHOOSE ONLY ONE OF THE FOLLOWING 7 marks 1 Describe in .pdf
CHOOSE ONLY ONE OF THE FOLLOWING 7 marks 1 Describe in .pdfCHOOSE ONLY ONE OF THE FOLLOWING 7 marks 1 Describe in .pdf
CHOOSE ONLY ONE OF THE FOLLOWING 7 marks 1 Describe in .pdf
 
Choose the correct answer 1 The method _ is called by the .pdf
Choose the correct answer 1 The method _ is called by the .pdfChoose the correct answer 1 The method _ is called by the .pdf
Choose the correct answer 1 The method _ is called by the .pdf
 
Choose your own project idea or select one of the following.pdf
Choose your own project idea or select one of the following.pdfChoose your own project idea or select one of the following.pdf
Choose your own project idea or select one of the following.pdf
 
choose the correct answer 1 Water will flow into the beaker.pdf
choose the correct answer 1 Water will flow into the beaker.pdfchoose the correct answer 1 Water will flow into the beaker.pdf
choose the correct answer 1 Water will flow into the beaker.pdf
 
Choose the best description of a cDNA library a mixture o.pdf
Choose the best description of a cDNA library a mixture o.pdfChoose the best description of a cDNA library a mixture o.pdf
Choose the best description of a cDNA library a mixture o.pdf
 
Choose an indicator from The Canadian Environmental Sustaina.pdf
Choose an indicator from The Canadian Environmental Sustaina.pdfChoose an indicator from The Canadian Environmental Sustaina.pdf
Choose an indicator from The Canadian Environmental Sustaina.pdf
 
Chapter 7 Business and the Environment 1 What is intrins.pdf
Chapter 7  Business and the Environment 1 What is intrins.pdfChapter 7  Business and the Environment 1 What is intrins.pdf
Chapter 7 Business and the Environment 1 What is intrins.pdf
 
Choose a major country to research Australia Write a repo.pdf
Choose a major country to research Australia Write a repo.pdfChoose a major country to research Australia Write a repo.pdf
Choose a major country to research Australia Write a repo.pdf
 
Choose an article from US News 2020 Public Health https.pdf
Choose an article from US News 2020 Public Health https.pdfChoose an article from US News 2020 Public Health https.pdf
Choose an article from US News 2020 Public Health https.pdf
 
Chinas Great FirewallChina has a population of over 14 bil.pdf
Chinas Great FirewallChina has a population of over 14 bil.pdfChinas Great FirewallChina has a population of over 14 bil.pdf
Chinas Great FirewallChina has a population of over 14 bil.pdf
 
Choose ALL that are TRUEWhich of the following commonly uses.pdf
Choose ALL that are TRUEWhich of the following commonly uses.pdfChoose ALL that are TRUEWhich of the following commonly uses.pdf
Choose ALL that are TRUEWhich of the following commonly uses.pdf
 
Choose a product or service that you are familiar with some.pdf
Choose a product or service that you are familiar with some.pdfChoose a product or service that you are familiar with some.pdf
Choose a product or service that you are familiar with some.pdf
 
Chinas GDP expanded at its slowest pace since the mid1970s.pdf
Chinas GDP expanded at its slowest pace since the mid1970s.pdfChinas GDP expanded at its slowest pace since the mid1970s.pdf
Chinas GDP expanded at its slowest pace since the mid1970s.pdf
 

Kürzlich hochgeladen

Unit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxUnit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxVishalSingh1417
 
PROCESS RECORDING FORMAT.docx
PROCESS      RECORDING        FORMAT.docxPROCESS      RECORDING        FORMAT.docx
PROCESS RECORDING FORMAT.docxPoojaSen20
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...EduSkills OECD
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactPECB
 
Unit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxUnit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxVishalSingh1417
 
Gardella_Mateo_IntellectualProperty.pdf.
Gardella_Mateo_IntellectualProperty.pdf.Gardella_Mateo_IntellectualProperty.pdf.
Gardella_Mateo_IntellectualProperty.pdf.MateoGardella
 
Gardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch LetterGardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch LetterMateoGardella
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Shubhangi Sonawane
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhikauryashika82
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfAyushMahapatra5
 
fourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingfourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingTeacherCyreneCayanan
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfJayanti Pande
 
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...christianmathematics
 
ICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxAreebaZafar22
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAssociation for Project Management
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104misteraugie
 

Kürzlich hochgeladen (20)

Unit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxUnit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptx
 
PROCESS RECORDING FORMAT.docx
PROCESS      RECORDING        FORMAT.docxPROCESS      RECORDING        FORMAT.docx
PROCESS RECORDING FORMAT.docx
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
 
Unit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxUnit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptx
 
Gardella_Mateo_IntellectualProperty.pdf.
Gardella_Mateo_IntellectualProperty.pdf.Gardella_Mateo_IntellectualProperty.pdf.
Gardella_Mateo_IntellectualProperty.pdf.
 
Gardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch LetterGardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch Letter
 
Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
 
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdf
 
fourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingfourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writing
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
 
ICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptx
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 

Check the Challenge 2 practice exercise as a reference Write.pdf

  • 1. Check the Challenge 2 practice exercise as a reference Write a function called isPatindrome which takes a string s and returns a Boolean value (True / False). Tip. You can use the same strategy as the exercise from Lab 06 where you had a collection of brackets and you checked if the string was valid. This function should: 1. Check if s is a palindrome (not case sensitive) - If so, return True - Otherwise, return False Example usage: print (ispalindrome("Anna")) "outputs the boolean value True print(ispalindrome("Book")) "outputs the boolean value False - A palindrome is a word, phrase, number or sequence of words that reads the same backward as forward. in our case, only checking for single word palindromes. Examples: - Anna - Civic - Kayak - Level - Madam - Mom - Noon - Racecar - Radar - Redder - Refer - Repaper