This study examines how a tinkering task in visual programming environments can provide opportunities for developing problem solving skills. We pursue this by analyzing eleven students in year 8 working with a tinkering task in a visual programming environment during a mathematics class. They were asked to create repeating patterns. Their work and discussions were analyzed through a lens of abstraction and decomposition, two elements of computational thinking. The analysis reveals how some students became thoroughly engaged in problem solving while others had a shallower experience of randomly manipulating the pre-made code. Since it was not the difficulty of the task but rather the random outcome of their manipulation of the code that determined whether they became engaged or not suggests that there is a need for support structures to fully tap into the potential of tinkering tasks to elicit problem solving.