How to create one resnet module for two kinds of classification

I want to use one resnet module for two kinds of classification.
Since the difference between the two is only the last fc layer, I want to make it share the features.
Is there any way this is possible?
I