# Effective Chat Patterns

## Effective Chat Patterns

### Code Explanation

```
Select code → Cmd+L →
"Explain what this code does step by step"
"What's the time complexity of this function?"
"Are there any bugs in this code?"
```

### Code Generation

```
"Write a function that [description]"
"Create a class that [description]"
"Implement [algorithm/pattern] in [language]"
```

### Refactoring Requests

```
Select code → Cmd+L →
"Refactor this to use async/await"
"Make this more readable"
"Extract this into smaller functions"
"Convert to TypeScript with proper types"
```

### Debugging

```
"Why is this code throwing [error]?"
"Debug this function - it returns [wrong result]"
"Find the bug: expected [X] but got [Y]"
```
