Dynamic Negative Compressibility of Few-Layer Graphene, h-BN, and MoS$_2$