for androidx.appcompat:appcompat in docs
Allows access to new APIs on older API versions of the platform (many using Material Design).
and for androidx.core:core in docs
Target the latest platform features and APIs while also supporting older devices.
The descriptions for both sound similar. But what is the difference between them? When we should use each one?