![subject](/tpl/images/cats/informatica.png)
Computers and Technology, 16.10.2020 18:01 tulensru02
Consider the following segment of code, which prompts the user for a string of lowercase characters (no capitals, spaces, digits, or punctuation) and prints True if the string is palindrome and false otherwise. This implementation is recursive and uses a deque. Because the user expects to provide a string instead of a deque instance, we use a wrapper function. The user calls is_palindrome and provides a string. is_palindrome forms a deque with the contents of the string and sends the deque object to the recursive rec_palindrome function. Both functions return Boolean values. Be sure not to include any unnecessary spaces in your answers. For example, keywords like and and or need spaces around them.
Operators such as== as and < do not.
from Deque_Generator import get _deque
def rec palindrome (dq): if return else:
if
return
else:
return
def is_palindrome (character_string)
dq-get_dequeO
for c in character_string:
return
print(is_palindrome (input ("Enter a phrase of lowercase characters only: ")))
![ansver](/tpl/images/cats/User.png)
Answers: 2
![](/tpl/images/ask_question.png)
![](/tpl/images/ask_question_mob.png)
Another question on Computers and Technology
![question](/tpl/images/cats/informatica.png)
Computers and Technology, 22.06.2019 00:30
Advantages and disadvantages of binary system
Answers: 1
![question](/tpl/images/cats/informatica.png)
Computers and Technology, 22.06.2019 05:00
Are special characters that allow you to search for multiple words at the same time.
Answers: 2
![question](/tpl/images/cats/informatica.png)
Computers and Technology, 23.06.2019 10:30
Would a ps4 wired controller work on an xbox one
Answers: 1
![question](/tpl/images/cats/informatica.png)
Computers and Technology, 23.06.2019 18:30
Where can page numbers appear? check all that apply. in the header inside tables in the footer at the bottom of columns at the top of columns
Answers: 1
You know the right answer?
Consider the following segment of code, which prompts the user for a string of lowercase characters...
Questions
![question](/tpl/images/cats/obshestvoznanie.png)
![question](/tpl/images/cats/ekonomika.png)
![question](/tpl/images/cats/health.png)
![question](/tpl/images/cats/User.png)
Engineering, 28.02.2020 20:53
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/himiya.png)
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/ekonomika.png)
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/fizika.png)
![question](/tpl/images/cats/biologiya.png)
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/mat.png)
![question](/tpl/images/cats/obshestvoznanie.png)
![question](/tpl/images/cats/istoriya.png)
History, 28.02.2020 20:53
![question](/tpl/images/cats/ekonomika.png)
![question](/tpl/images/cats/himiya.png)
![question](/tpl/images/cats/fizika.png)
![question](/tpl/images/cats/ekonomika.png)
![question](/tpl/images/cats/mat.png)
Mathematics, 28.02.2020 20:54