I'm sure there must be some leet-code-ish thing that gives embedded puzzles, about writing to hardware registers, and bit flipping, and race conditions between threads. But I don't know where it is, so I can't point you to anything.
If you want to get better at C++, you might start with Stroustrup's Tour. For C, I don't know what to say. You might also consider Rust, though I don't know if it has much traction in embedded yet.