Hi, Should be a fairly simple one if I understand what your after.
Get-Content -Path .\servers.txt | Get-ADComputer -Properties CanonicalName | Select Name, CanonicalName
Server.txt is just a plain text list of servers, one per line. If you wish to save the output you could you could add a Export-CSV to the end making it something like
Get-Content -Path .\servers.txt | Get-ADComputer -Properties CanonicalName | Select Name, CanonicalName | Export-Csv -Path server_paths.csv -NoClobber -NoTypeInformation