I feel your pain! It's really difficult to explain because there is no such thing in English. The closest structure that comes to my mind is something like this: "I was singing while taking a shower" (“Śpiewałem, biorąc prysznic”). In this example both activities happen at the same time. You can say: "Śpiewałem, robiąc jajecznicę" (="I was singing while making scrambled eggs"), "Robiąc jajecznicę, rozmawiałem z żoną"("I was making scrambled eggs while talking with my wife"), "Robiąc kanapki, słuchałem radia."("I was making sandwiches while listening to the radio") "Robiąc" is some kind of a verb, NOT a noun. It indicates that something is happened at the same time as the other activity. Just use things like “robiąc” referring to other verbs. If I were you, I would remember these examples and build sentences similar to them. We do the same in phrases like:
“I was singing while listening to the radio.”
You can learn by heart some phrases:
"___________to dla niego czarna magia"
"___________to dla niego pestka"
"___________to dla niego bułka z masłem"
You should replace __________with a noun or verbal noun, such as:
"Matematyka to dla niego czarna magia."
"Nauka polskiego to dla niego pestka."
"Rozwiązywanie zadań to dla niego bułka z masłem."