Python help pls!!?

I need a function that "Given arbitrary values s and t, return True if both values are strings and s is a substring of t."

Chris2016-02-11T12:50:46Z

Audrey, pls.
s in t, not "s" in "t".
You need to check the strings that were passed to the function, not the literal characters "s" and "t".

Also, like last time, you don't need "return True" and "return False", since the expression will evaluate to either True or False and you can thus return the expression itself.


def is_substring(s, t):
... return type(s) is str and type(t) is str and s in t


Also, people usually acknowledge in some form that their question was answered before posting a new one.