Conditional starting with "had"

Is the following sentence correct?

Had I had a lamp, I would have had light.


There is a conditional clause without 'if'. In this case we use an inverted order of words /like in yes-no questions/. So the sentence is grammatically correct.