diff --git a/build.py b/build.py index e69de29..2000720 100644 --- a/build.py +++ b/build.py @@ -0,0 +1,17 @@ +def is_rotation(s1,s2): + if s1 == None: + return False + elif s1 == '' and len(s2) != 0: + return False + elif s1 == '' and s2 == '': + return True + elif len(s1) != len(s2): + return False + else: + for i in range(len(s1)): + if s1[i:] and s2[:i]: + return True + +s1 = 'foobarbaz' +s2 = 'barbazfoo' +is_rotation(s1,s2) diff --git a/build.pyc b/build.pyc new file mode 100644 index 0000000..4b76aa5 Binary files /dev/null and b/build.pyc differ diff --git a/tests/__init__.pyc b/tests/__init__.pyc new file mode 100644 index 0000000..50f7aa8 Binary files /dev/null and b/tests/__init__.pyc differ diff --git a/tests/test_is_rotation.pyc b/tests/test_is_rotation.pyc new file mode 100644 index 0000000..0454a68 Binary files /dev/null and b/tests/test_is_rotation.pyc differ