kyu_5.moving_zeros_to_the_end package
Submodules
kyu_5.moving_zeros_to_the_end.move_zeros module
Solution for -> Moving Zeros To The End.
Created by Egor Kostan. GitHub: https://github.com/ikostan
kyu_5.moving_zeros_to_the_end.test_move_zeros module
Test for -> Moving Zeros To The End.
Created by Egor Kostan. GitHub: https://github.com/ikostan
- class kyu_5.moving_zeros_to_the_end.test_move_zeros.MoveZerosTestCase(methodName='runTest')[source]
Bases:
TestCaseTesting move_zeros function.
- _classSetupFailed = False
- _class_cleanups = []
- test_move_zeros = None
- test_move_zeros_00(**kw)
Testing move_zeros function with various test data [with array=[1, 2, 0, 1, 0, 1, 0, 3, 0, 1], expected=[1, 2, 1, 1, 3, 1, 0, 0, 0, 0]].
Test an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements. :return:
- test_move_zeros_01(**kw)
Testing move_zeros function with various test data [with array=[9, 0.0, 0, 9, 1, 2, 0, 1, 0, 1, 0.0, 3, 0, 1, 9, 0, 0, 0, 0, 9], expected=[9, 9, 1, 2, 1, 1, 3, 1, 9, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]].
Test an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements. :return:
- test_move_zeros_02(**kw)
Testing move_zeros function with various test data [with array=[‘a’, 0, 0, ‘b’, ‘c’, ‘d’, 0, 1,…1, 0, 3, 0, 1, 9, 0, 0, 0, 0, 9], expected=[‘a’, ‘b’, ‘c’, ‘d’, 1, 1, 3, 1,…9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]].
Test an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements. :return:
- test_move_zeros_03(**kw)
Testing move_zeros function with various test data [with array=[‘a’, 0, 0, ‘b’, None, ‘c’, ‘d’,… [], 0, 1, 9, 0, 0, {}, 0, 0, 9], expected=[‘a’, ‘b’, None, ‘c’, ‘d’, 1, Fa…9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]].
Test an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements. :return:
- test_move_zeros_04(**kw)
Testing move_zeros function with various test data [with array=[0, 1, None, 2, False, 1, 0], expected=[1, None, 2, False, 1, 0, 0]].
Test an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements. :return:
- test_move_zeros_05(**kw)
Testing move_zeros function with various test data [with array=[‘a’, ‘b’], expected=[‘a’, ‘b’]].
Test an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements. :return:
- test_move_zeros_06(**kw)
Testing move_zeros function with various test data [with array=[‘a’], expected=[‘a’]].
Test an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements. :return:
- test_move_zeros_07(**kw)
Testing move_zeros function with various test data [with array=[0, 0], expected=[0, 0]].
Test an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements. :return:
- test_move_zeros_08(**kw)
Testing move_zeros function with various test data [with array=[0], expected=[0]].
Test an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements. :return:
- test_move_zeros_09(**kw)
Testing move_zeros function with various test data [with array=[False], expected=[False]].
Test an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements. :return:
- test_move_zeros_10(**kw)
Testing move_zeros function with various test data [with array=[], expected=[]].
Test an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements. :return:
Module contents
Moving Zeros To The End.