Use Ansible to get OS package version (even with a dash)

ansible package version
Get the OS package versions using Ansible, addressing challenges with package names containing dashes. The process involves using the package_facts module. Despite complexities, the approach ensures accurate version retrieval, even with dashes in package names.