It’s 8.
Let’s break it down.
Let’s count the number of electrons in the H2CO molecule:
H=1, but 2(1) =2
C = 4
= 6
Total = 12
Let’s get the diagram with carbon in the middle, bonded to H, H, and O. We will arrive at something with a t-shape:
H-C-H
O
We’ve used 6 electrons so far (we have 3 bonds). We will subtract these 6 electrons from the total number of the electron we arrived at. Therefore, 12-6 = 6.
Finishing the carbon quartet, we see carbon has 3 bonds and a pair of electrons, that is,
6-2 =4
Putting the 4 electrons around O will actually put 6 electrons on O (4 in lone pairs, 2 in bonds)
We will have a double bond between O and C:
H2-C=O
has two pairs of lone electrons, that is 4. We have 2 bonds to O and 2 bonds to H, making it 4.
2(4) =8
Answer = Carbon uses 8 electrons to bond.