Args: inp (str): The decoded input. Returns: str: The encoded output.
(inp)
| 134 | |
| 135 | @staticmethod |
| 136 | def encode(inp): |
| 137 | """ |
| 138 | Args: |
| 139 | inp (str): The decoded input. |
| 140 | |
| 141 | Returns: |
| 142 | str: The encoded output. |
| 143 | """ |
| 144 | inp = str(inp) |
| 145 | outp = "" |
| 146 | for i in inp: |
| 147 | if i in letters: |
| 148 | outp = f"{outp}{letters.index(i)}" |
| 149 | else: |
| 150 | outp += str(letters.index(" ")) |
| 151 | return outp |
| 152 | |
| 153 | @staticmethod |
| 154 | def replace_char(old_char, new_char): |
no test coverage detected