All pastes #2536950 Raw Edit

rec

public unlisted text v1 · immutable
#2536950 ·published 2014-01-14 05:44 UTC
rendered paste body
        public static bool isSubstring(string s1, string s2)
        {
            if (s1.Length == 0 || s2.Length == 0)
                return true;
            if (s1.Length < s2.Length)
                return false;
            if (s1[0] == s2[0])
                return isSubstring(s1.Substring(1), s2.Substring(1));
            else
                return isSubstring(s1.Substring(1), s2);
        }