Checking array with two elements possible or not .
if ( xorr == 1 && mid == 1 ) { Console . WriteLine ( " Array ▁ size ▁ is ▁ " + 3 ) ; Console . WriteLine ( " Array ▁ is ▁ " + xorr + " ▁ " + mid + " ▁ " + mid ) ; } else { Console . WriteLine ( " Array ▁ size ▁ is ▁ " + 2 ) ; Console . WriteLine ( " Array ▁ is ▁ " + ( xorr + mid ) + " ▁ " + mid ) ; } }