title: Way to determine if a group of touching nodes assigned values in a graph can be added to a specific value?
body: <p>I have abstracted my actual problem into a more general graph problem for the sake of asking.</p>
  
  <p>I have an undirected graph where each node is assigned an integer. How can I determine whether or not there exists in the graph a group of touching nodes that add to a specific value?</p>
  
  <p><img src="https://i.stack.imgur.com/bwDUi.png" width="300" height="300" alt="An example graph"></p>
  
  <p>Edit: More specifics: I have a grid of tiles that are labeled with either a positive or negative integer. A single "move" would be to combine any one tile with an adjacent tile (not diagonal), leaving a gap in the grid behind. If the tile being combined into has a value of zero now, it also is removed. I basically need to do a test after every time a tile that has a value of 0 is removed in order to see if any more possible "moves" that result in values of 0 exist in the grid, even if it takes multiple combinations to get to them.</p>
  
  <p>The grid is only 6x6.</p>
  
  <p>I suppose since I only need to test if at least one "zeroing" still exists in the grid, most of the time it wouldn't be hitting the worst case. It can stop searching as soon as it finds one.</p>