Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $a = "1", "Computer Name", "2"
- $b = "3", "4", "Full Computer Name Here"
- foreach ($line in $a) {
- foreach ($line2 in $b) {
- where "*$line*" -like "*$line2*"
- }
- }
- $a = "1","Computer Name","2"
- $b = "3","4","Full Computer Name Here"
- foreach ($line in $a ) {
- $b -match $line
- }
- foreach ($line in $a) {
- $b | Where-Object { $_ -like "*${line}*" }
- }
- foreach ($line in $a) {
- foreach ($line2 in $b) {
- if ($line2 -like "*${line}*") { $line2 }
- }
- }
- foreach ($line in $a) {
- $b -like "*${line}*"
- }
Add Comment
Please, Sign In to add comment