| Conditions | 1 |
| Total Lines | 13 |
| Code Lines | 3 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | def count_truthy(items): |
||
| 20 | def to_camel_case(snake_str): |
||
| 21 | """ |
||
| 22 | Convert snake case to CamelCase |
||
| 23 | ----- |
||
| 24 | examples: |
||
| 25 | |||
| 26 | 1) to_camel_case('snake_cased_string') -> 'SnakeCasedString' |
||
| 27 | ----- |
||
| 28 | :param snake_str: str |
||
| 29 | :return: str |
||
| 30 | """ |
||
| 31 | components = snake_str.split('_') |
||
| 32 | return components[0].title() + ''.join(x.title() for x in components[1:]) |
||
| 33 |
The coding style of this project requires that you add a docstring to this code element. Below, you find an example for methods:
If you would like to know more about docstrings, we recommend to read PEP-257: Docstring Conventions.