Will a engine from a 1990 olds 98 regency work in a 1992 olds 88 both 3.8 engines and auto trans?

they both have to be front or rear wheel drive, you cant do it if one is front, and the other is rear