T
T
TechNOIR2018-09-19 17:34:10
PowerShell
TechNOIR, 2018-09-19 17:34:10

Powershell. How to compare two full names and highlight the different elements?

Good afternoon.
Tell me please. Powershell. How can you compare two full names and highlight the different elements?
I compare using compare-object.
Let's say there are two full names "Ivanov Ivan Ivanovich" and "Ivanov Ivan Albertych". It is necessary that Ivanov Ivan Ivanovich gave out the first name (highlighted in bold what is different) and in brackets the second name)
Ie the result:
Ivanov Ivan Ivanovich (Ivanov Ivan Albertych)
Is it possible?
thanks in advance

Answer the question

In order to leave comments, you need to log in

1 answer(s)
L
LoGIc89, 2018-09-20
@LoGIc89

In what form do you have this data? Two text files? Or a set of objects with properties like Name, Surname, etc.?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question