Skip to main content
1 of 3

APL (Dyalog), 69 bytes

f←{({(⍵,(0×⍵),⍵){⍺⍪⍵⍪⍺}⍵,⍵,⍵}⍣⍵)1 1⍴1} 

Output is a 2-dimensional array with 1 representing H and 0 representing space. Try it online!