The D Flip-flip is the synchronous (clocked) sibling of the D latch.
There are various ways of constructing a D flip-flip from fundamental logic units, here I’m using only NAND gates. And there we have it - 1 bit of memory in a clocked register! It’s nice to see it work, even if this circuit is no longer of any real practical use.
As always, all notes, schematics and code are in the Little Electronics & Arduino Projects repo on GitHub