in reply to num keys of the hash within hash?

What have you tried? That's really the best way to do these.

I think something along the lines of scalar @{hash{first}} should work, although I haven't tried it at the moment.