General solution of higher-order PDEs with constant coefficients