kyu_6.string_subpattern_recognition_2 package
Submodules
kyu_6.string_subpattern_recognition_2.has_subpattern module
Solution for -> String subpattern recognition II.
Created by Egor Kostan. GitHub: https://github.com/ikostan
- kyu_6.string_subpattern_recognition_2.has_subpattern.has_subpattern(string: str) bool[source]
Recognition of string subpattern II.
if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result.
- Parameters:
string
- Returns:
kyu_6.string_subpattern_recognition_2.test_has_subpattern module
Test for -> String subpattern recognition II.
Created by Egor Kostan. GitHub: https://github.com/ikostan
- class kyu_6.string_subpattern_recognition_2.test_has_subpattern.HasSubpatternTestCase(methodName='runTest')[source]
Bases:
TestCaseTesting ‘has_subpattern’ function.
- _classSetupFailed = False
- _class_cleanups = []
- test_has_subpattern = None
- test_has_subpattern_00_a(**kw)
Testing ‘has_subpattern’ function with various test data [with string=’a’, expected=False].
Verify that ‘has_subpattern’ function to returns either true/True or false/False if a string can be seen as the repetition of a simpler/shorter subpattern or not.
1. if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
2. the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result. :return:
- test_has_subpattern_01_aaaa(**kw)
Testing ‘has_subpattern’ function with various test data [with string=’aaaa’, expected=True].
Verify that ‘has_subpattern’ function to returns either true/True or false/False if a string can be seen as the repetition of a simpler/shorter subpattern or not.
1. if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
2. the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result. :return:
- test_has_subpattern_02_abcd(**kw)
Testing ‘has_subpattern’ function with various test data [with string=’abcd’, expected=False].
Verify that ‘has_subpattern’ function to returns either true/True or false/False if a string can be seen as the repetition of a simpler/shorter subpattern or not.
1. if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
2. the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result. :return:
- test_has_subpattern_03_babababababababa(**kw)
Testing ‘has_subpattern’ function with various test data [with string=’babababababababa’, expected=True].
Verify that ‘has_subpattern’ function to returns either true/True or false/False if a string can be seen as the repetition of a simpler/shorter subpattern or not.
1. if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
2. the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result. :return:
- test_has_subpattern_04_ababababa(**kw)
Testing ‘has_subpattern’ function with various test data [with string=’ababababa’, expected=False].
Verify that ‘has_subpattern’ function to returns either true/True or false/False if a string can be seen as the repetition of a simpler/shorter subpattern or not.
1. if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
2. the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result. :return:
- test_has_subpattern_05_123a123a123a(**kw)
Testing ‘has_subpattern’ function with various test data [with string=’123a123a123a’, expected=True].
Verify that ‘has_subpattern’ function to returns either true/True or false/False if a string can be seen as the repetition of a simpler/shorter subpattern or not.
1. if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
2. the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result. :return:
- test_has_subpattern_06_123A123a123a(**kw)
Testing ‘has_subpattern’ function with various test data [with string=’123A123a123a’, expected=False].
Verify that ‘has_subpattern’ function to returns either true/True or false/False if a string can be seen as the repetition of a simpler/shorter subpattern or not.
1. if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
2. the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result. :return:
- test_has_subpattern_07_12aa13a21233(**kw)
Testing ‘has_subpattern’ function with various test data [with string=’12aa13a21233’, expected=True].
Verify that ‘has_subpattern’ function to returns either true/True or false/False if a string can be seen as the repetition of a simpler/shorter subpattern or not.
1. if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
2. the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result. :return:
- test_has_subpattern_08_12aa13a21233A(**kw)
Testing ‘has_subpattern’ function with various test data [with string=’12aa13a21233A’, expected=False].
Verify that ‘has_subpattern’ function to returns either true/True or false/False if a string can be seen as the repetition of a simpler/shorter subpattern or not.
1. if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
2. the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result. :return:
- test_has_subpattern_09_abcdabcaccd(**kw)
Testing ‘has_subpattern’ function with various test data [with string=’abcdabcaccd’, expected=False].
Verify that ‘has_subpattern’ function to returns either true/True or false/False if a string can be seen as the repetition of a simpler/shorter subpattern or not.
1. if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
2. the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result. :return:
- test_has_subpattern_10_w9TkPyHgTygqGTCBnL94FFa5q1uvyBzCOFdzFGl3439FCsk59yjq_A7nT9g3N94nTzFkCy31AkN2Hdd2Fmyn5VFGCBN5n931mkaw14bXw_Aywzw1TwyoAB2yLdydPGALFv51Bj0Vnnd1VayBTsun1TV31yPmbj_PNaq1kuXoVGkokjTTd2LFbOV7n2XTayLnbBsTFmsdHuVaykF0V23_w3slOymC1OF4akgo5yGLFsGF139oTG7GsuuvVPwTy3dm5oglTlF4_FlqkNyFVFGvm1VuljHggH74nFwCFLy0n0qALdy0o4yyw592BovN7_Bvy1AGwVngklvBGB204H2BTXjAykyXBFja5ov4jTkTGybBnATCvO_llwGClTmvw9os9TyH41vvjmkVXdTw3aysnTBPTvvgmA51wvkn1T7_1OyyGLPgV9LdmqyldTwbdu0TqTH377kOynv3Byd0vVlynTkAyyj1_1dqyv5FN1TsTyv5Gajgvd0Xn2dCjvFXq3lykg7soolyksllVGNkV_3VFLqwvnyBPH1T1NoBuzLnmlC5lO7FlHFwNVT1AuGT2zNsdVodnl_TdnnnwOdNTg5qH0PPXl5FljvOu0vyqBFXLTz9uvAzP5b1lTkHG5a_TqzzwCOkwl0dBVGjbkdFFy4TljFaTGBdAVGT1luFVnByHvn2XvAB_lAOGw77BjTg1k5yV17ddCmP14GvL2P5XBTkTw95v3ksv5kqkyuCy_X430BAy2AB5NlC5wXbOv4zgVl9GLb5wBzaNdT7vyzslPBkws5Nw2_w0nvN1V5dG4qzLX7dsV1ujGu0lzVbmPkVB59sVVoVFBHPyOuygO0_ClwmA2bGkHLVayBb5Cayl2m9w4TBgkGbTw0lHB2VG5NnFwyF17Gk_Tn5TdH7HVnlyvG51do9k35zO4aqmPBTwnXu5wdBvvTPdL715ln4o_jGVTTlgks119kuCV3Ta5vLa7nqmdolmjPG5wqGynXG2n1XTCbz10_BadOFvTbbgHOnywVG50wwNnzObkddNF5BGzobX(**kw)
Testing ‘has_subpattern’ function with various test data [with string=’w9TkPyHgTygqGTCBnL94FFa5q1uvyBz…bbgHOnywVG50wwNnzObkddNF5BGzobX’, expected=True].
Verify that ‘has_subpattern’ function to returns either true/True or false/False if a string can be seen as the repetition of a simpler/shorter subpattern or not.
1. if a subpattern has been used, it will be repeated at least twice, meaning the subpattern has to be shorter than the original string;
2. the strings you will be given might or might not be created repeating a given subpattern, then shuffling the result. :return:
Module contents
String subpattern recognition II.