Optimizing a boolean expression to (NAND,AND,NOT) system
Complement Law says \$\overline{\overline{X}} = X\$. 

$$\overline A\ \overline B\ \overline C + \overline A\ B\ C + A\ B\ D + A\ \overline B\ \overline D$$

Take Double Complement.
$$\overline{\overline{\overline A\ \overline B\ \overline C + \overline A\ B\ C + A\ B\ D + A\ \overline B\ \overline D}}$$

Use DeMorgan's to remove lower complement.
$$\overline{\overline{\overline A\ \overline B\ \overline C} ∙ \overline{\overline A\ B\ C} ∙ \overline{A\ B\ D} ∙ \overline{A\ \overline B\ \overline D}}$$

4 NOTs, 4 3-input NANDs, 1 4-input NAND.