kyu_8.counting_sheep package

Submodules

kyu_8.counting_sheep.counting_sheep module

kyu_8.counting_sheep.counting_sheep.count_sheeps(arrayOfSheeps: list) → int[source]

Consider an array of sheep where some sheep may be missing from their place. We need a function that counts the number of sheep present in the array (true means present).

Hint: Don’t forget to check for bad values like null/undefined :param arrayOfSheeps: :return:

kyu_8.counting_sheep.test_counting_sheep module

class kyu_8.counting_sheep.test_counting_sheep.CountingSheepTestCase(methodName='runTest')[source]

Bases: unittest.case.TestCase

Testing ‘count_sheeps’ function

test_counting_sheep()[source]

Testing ‘count_sheeps’ function Consider an array of sheep where some sheep may be missing from their place. We need a function that counts the number of sheep present in the array (true means present). :return:

test_counting_sheep_bad_input()[source]

Testing ‘count_sheeps’ function Hint: Don’t forget to check for bad values like null/undefined :return:

test_counting_sheep_empty_list()[source]

Testing ‘count_sheeps’ function Hint: Don’t forget to check for bad values like empty list :return:

test_counting_sheep_mixed_list()[source]

Testing ‘count_sheeps’ function Hint: Don’t forget to check for bad values like mixed list :return:

Module contents