#compsci #python 

## [[Метод .find()|.find()]]

## [[Метод .split()|.split()]]

## .replace()
.replace() replaces occurrences of a substring with another
```python
S='Spam'
S.replace('pa','XYZ')
# S = 'SXYZm'
```

## .rstrip()
.rstrip() removes whitespace characters on the right side of a string
```python
S='aaa\n'
S=S.rstrip()
# S = 'aaa'
```

## .format()
![[Python formatted output#^68a884]]

## .rfind()
Like .find(), except it searches from the right instead of from the left
Syntax:
```python
S.rfind(str, [start], [end])
```

## ord()
Transforms a symbol into its ASCII code
Syntax:
```python
ord(S)
```

## chr()
Transforms an ASCII code into a symbol
Syntax:
```python
chr(S)
```