MCPcopy Create free account
hub / github.com/ActiveState/code / multiline

Function multiline

recipes/Python/415345_write_sql_via_python/recipe-415345.py:53–62  ·  view source on GitHub ↗

r"""multiline >>> multiline('Hello there') False >>> multiline('\n'.join(['Hello', 'there'])) True

(s)

Source from the content-addressed store, hash-verified

51 return self.template % t
52
53def multiline(s):
54 r"""multiline
55
56 >>> multiline('Hello there')
57 False
58
59 >>> multiline('\n'.join(['Hello', 'there']))
60 True
61 """
62 return s.find('\n') >= 0
63
64class Source(object):
65 """Source

Callers 1

__str__Method · 0.85

Calls 1

findMethod · 0.45

Tested by

no test coverage detected