7,023 questions
There are plenty of examples and tutorials on the net.
https://morgantechspace.com/2015/05/powershell-export-ad-computers-to-csv.html
https://www.hofferle.com/generating-lists-of-computer-names-with-powershell/
https://www.bing.com/search?q=powershell%20export%20list%20of%20computer%20ad