我有一个文本文件,每行有两个值,用空格分隔.现在我想知道其中一列中的重复值.是否可以使用Windows PowerShell实现此目的.
给定一个文本文件:
Apple Fruit Banana Fruit Carrot Vegetable
期望的输出是:(我想在第二列中找到重复项)
Fruit
powershell powershell-2.0 powershell-3.0 powershell-4.0
powershell ×1
powershell-2.0 ×1
powershell-3.0 ×1
powershell-4.0 ×1