Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Python Python Collections (2016, retired 2019) Tuples Stringcases

stringcases. the last part of the task is not very clear.

hi, i managed to do the first three points. def stringcases (string): tuple = (string.upper(), string.lower(), string.title()) return tuple

However, i dont understand what Reversed needs to do. convert lower case to upper case?

many thanks.

stringcases.py
def stringcases (string):
    for i in string:
        i = i.capitalize()

    tuple = (string.upper(), string.lower(), string.capitalize())
    return tuple

3 Answers

Steven Parker
Steven Parker
231,275 Points

What they mean by "Reversed" is to make the string read backwards.

As the hint says, there's no function for that one (but it can be easily done with a slice!).

Sneha Nagpaul
Sneha Nagpaul
10,124 Points

Reversed should simply reverse the string. "Mikhail" -> "liahkiM'

Many thanks. done now.