Conceptual doubt

Suppose we have 2 binary classification problems , say one for digits (0 vs 1 ) and other for a different set of images ( bike vs car). Will the same layers used for problem 1 work for problem 2 as well. How do we decide on number of neurons and number of layers required . Also how does same type of neuwons work for both different problems. ? Please explain . Thank you

If the input is images, you can use similar architectures.

You decide on the number of layers and units per layer by experimentation.

One set of goals is to get acceptably good performance with the simplest possible system, as it will be less expensive to train.