Is it possible to combine information from two blocks from a matrix to an if function? I have a check box field called requiredPrograms, in it it has a selection of programs you can choose from. This is within a matrix field called Work shop Instructor which is for my workshop channel.

On my outside workshop page I'd like to display what programs are required for all the teachers at the workshop in the one spot. On the inner page they would be broken into separate programs per instructor.

I've done the inner page with no issue but I cannot figure out a way to do the outer one.

{% for block in entry.workshopInstructor[0] and entry.workshopInstructor[1] %}
   {% if block.requiredPrograms.contains('Photoshop')%}
      &lt;p&gt;Foo&lt;/p&gt;
   {% endif %}
{% endfor %}


That is my current attempt but this results in nothing being displayed and other attempts have only produced the output twice.

Any suggestions?
The question is a little unclear, is this what you are looking for?

{% set requiredProgram = false %}
{% for block in entry.workshopInstructor %}
   {% if block.requiredPrograms.contains('Photoshop')%}
      {% set requiredProgram = true %}
   {% endif %}
{% endfor %}

{% if requiredProgram %}
  Photoshop is enabled on one of this entry's blocks field.
{% endif %}