Solve a typical LINQ problem using Select, OrderBy and Limit.
Asked in the HackerRank coding challenge (75 minutes) stage. This was the second problem in the 75-minute HackerRank screen and was rated easy.
Use the provided users and user_profiles tables. Return users even when no matching profile exists.
user_id, user_name, city, and created_at.created_at descending, then user_id ascending to break ties.| Column | Type | Description |
|---|---|---|
| user_idPK | INT | Unique user identifier |
| user_name | VARCHAR(100) | User display name |
| created_at | DATE | Date the user was created |
| Column | Type | Description |
|---|---|---|
| profile_idPK | INT | Unique profile identifier |
| user_id | INT | Referenced user identifier |
| city | VARCHAR(80) | User city |