```
string.getBytes(StandardCharsets.UTF_8).length
```