Step-by-step explanation:
Let the number of hens be
![=x](https://img.qammunity.org/2023/formulas/mathematics/college/1ye1eo60321kt0irebsbvlxoc6mkb0xjkb.png)
Let the number of goats be
![=y](https://img.qammunity.org/2023/formulas/mathematics/high-school/eyqg7ht214ag7yrcgx5vsdv0indwor49dl.png)
The number of animals on the farm is
![=19](https://img.qammunity.org/2023/formulas/mathematics/high-school/h8a9xpl3d72m2qqcxgdtl6ys9977ybot4k.png)
This can be represented in an equation below as
![x+y=19-----(1)](https://img.qammunity.org/2023/formulas/mathematics/college/mn9frpom1su3309fjr6udavdwvu4aznfay.png)
The number of legs given in the question is
![=68](https://img.qammunity.org/2023/formulas/mathematics/college/z1wvjjh7q5519608q5beq0gj03qv6nf9kv.png)
Hens have 2 legs
Goats have 4 legs
So the number of legs can be represented in the equation below as
![2x+4y=68-----(2)](https://img.qammunity.org/2023/formulas/mathematics/college/83jqhu7zv4s98zfoszho6nr8uy7qdihvor.png)
Step 1:
We will solve equations (1) and (2) simultaneously
![\begin{gathered} x+y=19----(1) \\ 2x+4y=68----(2) \end{gathered}](https://img.qammunity.org/2023/formulas/mathematics/college/3bzw7mg8ml3miv2c7oamvqxmu7sgadfmcn.png)
From equation (1), we will make x the subject of the formula
![\begin{gathered} x+y=19 \\ x=19-y-----(3) \end{gathered}](https://img.qammunity.org/2023/formulas/mathematics/college/4k5ytups6b7jn5gd7yfq11e4z9d7wrz0w5.png)
Step 2:
Substitute equation (3) in equation (2)
![\begin{gathered} 2x+4y=68 \\ 2(19-y)+4y=68 \\ 38-2y+4y=68 \\ 38+2y=68 \\ collect\text{ similar terms, we will have} \\ 2y=68-38 \\ 2y=30 \\ divide\text{ both sides by 2} \\ (2y)/(2)=(30)/(2) \\ y=15 \end{gathered}](https://img.qammunity.org/2023/formulas/mathematics/college/utme457shzgdl878ncy60gqoylskevhwi3.png)
Hence,
The number of goats on the farm is
![\Rightarrow15](https://img.qammunity.org/2023/formulas/mathematics/college/d13jhegyickrn27kbvyrb30b5rmhydpg0n.png)