Geometry of the complex of a steroid hormone, dexamethasone, with a hexanucleotide sequence from the glucocorticoid responsive element d(TGTTCT)2, is optimised here using computer aided geometry simulation with an energy minimization technique. We have also optimised its geometries with genetically modified and arbitrarily chosen DNA sequences. The drug molecule is considered to have both intercalative as well as non-intercalative binding. Comparison of energetics and stereochemical aspects, as well as the H-bonding scheme, is used here to bring out salient features about the mechanism of DNA sequence recognition by steroid hormones.