Pandas 
IntuitionApproachComplexity
Time complexity:

Space complexity:
Codedef find_valid_emails(users: pd.DataFrame) -> pd.DataFrame:
users['is_valid'] = users['email
# Intuition
<!-- Describe your first thoughts on how to solve this problem. -->

# Approach
<!-- Describe your approach to solving the problem. -->

# Complexity
- Time complexity:
<!-- Add your time complexity here, e.g. $$O(n)$$ -->

- Space complexity:
<!-- Add your space complexity here, e.g. $$O(n)$$ -->

# Code
```pythondata []
import pandas as pd
import re

def is_valid_email(email: str) -> bool:
    pattern = r'^[\w]+@[a-zA-Z]+\.(com)
```
    return bool(re.match(pattern, email))

def find_valid_emails(users: pd.DataFrame) -> pd.DataFrame:
    users['is_valid'] = users['email'].apply(is_valid_email)
    valid_emails = users[users['is_valid']]
    valid_emails_sorted = valid_emails.sort_values(by='user_id')
    valid_emails_sorted = valid_emails_sorted.drop(columns=['is_valid'])
    return valid_emails_sorted
   
```
['Pandas']