Yes, although your original post uses V which I assume is the volume of one mole at the specified pressuire and N which I assume is Avogadro's number. To apply to any size container, that specification has to be changed.
Since N/V = n, where n is the number density of molecules per unit volume, the equation becomes
P = nm<c>2/3. This would apply to any shape and size of macroscopic container.
It would help a lot if you would define the terms used in the OP. Not all authors use the same common terms in the same way. For instance, the term c is often used to designate the speed of light in a vacuum, and p is often used to designate momentum.