How do i compare item in 2 list? Currently i have 2 list with the following append(using append item to list activity)
List 1 : A B C D
List 2 : B D
Would want to get true false output
How do i compare item in 2 list? Currently i have 2 list with the following append(using append item to list activity)
List 1 : A B C D
List 2 : B D
Would want to get true false output
Hi,
What is expected result to the above sample?
Do you need to compare if both lists are exactly same including their order?
Regards,
makefileCopy code
isMatch = List1.Contains(currentItem)
Here, List1
represents the first list, and currentItem
represents the current item in List 2.
4. If the comparison in step 3 results in a match, set the “isMatch” variable to True using another “Assign” activity.
Hi @rayz1503
The "SequenceEqual" method compares the elements of two sequences (in this case, lists) and returns True if they have the same elements in the same order. Otherwise, it returns False.
The Output returns False
Hi @rayz1503
List1= New List(of String) from {"A","B","C","D"}
List2= New List(of String) from {"B","D"}
currentItem=Item.ToString
List2.Contains(Item)
Note: Attached workflow for your reference
Sequence7.xaml (10.1 KB)
Hope it helps!!
Regards,
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.