The Daily CLAD

Community Browser
cancel
Showing results for 
Search instead for 
Did you mean: 

CLAD2017 - Answer the requirement: Find those ones

SercoSteveB
Active Participant

You are tasked with writing a VI that searches an input array of U8 numeric values (Data Array In) and identifies which elements within that array contain values that have one or more of the same BITs set to B'1' as those in a match U8 numeric (Match Value) .  Elements in the input array that have one or more of the same BITs set to B'1' as those in the match numeric should be added to a U8 array returned by the VI (Matched Elements Array Out).  Which of the following VIs does NOT satisfy those requirements?

 

Example: If the Match Value = 5 (B'00000101) only elements from Data Array In with BIT2 and/or BIT0 set to B'1' should be included in Matched Elements Array Out.

 

Have a go at coding a VI yourself or expand the Spoiler tag to see the answer options:

 

Spoiler

a)

Match Ones #1.png

 

 

 

b)

Match Ones #2.png

 

 

c)

Match Ones #3.png

 

d)

Match Ones #4.png

 

 

Comments