In this paper, we generalize the lifted polynomials which generate reversible codes over F-q, a finite field with q element. Lifted polynomials are introduced by the authors Oztas and Siap [Lifted polynomials over F-16 and their applications to DNA codes, Filomat 27(3) (2013), pp. 459-466] over F-16. Lifted polynomials have proven to be very advantageous. They are easy to construct and they can be used to construct codes with specific properties such as dimension and the length of codes. We also generalize the 4(k)-lifted polynomials which lead to reversible and reversible complement DNA codes over . Further we construct examples of codes over F-8, F-9, F-16 and F-256 that have the best possible parameters or attain the Griesmer bound, hence they are optimal codes generated by lifted polynomials.