A slight modification of the example posted by @Andreas Baumgarten .
There's no need to create an intermediate array (i.e. the variable $PCLIST), and the -Filter can be adjusted to replace the need for the Where-Object.
Get-ADComputer -SearchBase 'OU=MyComputerOU, dc=contoso, dc=co, dc=nz' -Filter "name -like 'sales*'" |
Select-Object -Expand Name |
Sort-Object |
Out-File -FilePath TestComputer.txt
Because you're "new to PowerShell" there are quite a few instructional articles, demonstrations, etc. to e found on the web. But probably the best place to start would be with this book (it's a free PDF download): Windows-PowerShell-4
Ignore the fact that it's PowerShell version 4. There are only trifling differences between that version and 5.1. Oh, and just ignore the advertisements and praise for Sapien found throughout the book. Sapien's a company that makes good products, but you don't need them now (and you may never need them).
Get yourself a good editor (VS Code and Virtual Studio are both free) and install the necessary addons to make coding PowerShell a lot easier. You won't regret it.