Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Part 1: center_me Create a function center me which takes a list of strings. It then returns a new list of strings with each string
Part 1: center_me Create a function center me which takes a list of strings. It then returns a new list of strings with each string padded with blanks such that if you printed the strings, it would be centered. You cannot use the center function (it's a method on the string type). Below is a screen shot of what the solution should look like ["I LIKE", "Dogs", "Black Dogs, Green Dogs", "Bad Dogs, Mean Dogs", "All kinds of Dogs","I like Dogs","Dogs" for e in center me (a): print (e) Python 3.6.1 (default, Dec 2015, 13:05:11) [GCC 4.8.2] on linux I LIKE Dogs Black Dogs, Green Dogs Bad Dogs, Mean Dogs All kinds of Dogs I like Dogs Dogs
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access with AI-Powered Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started