A genie could be made to act like an oracle if the only commands we ever give it are to answer certain questions. An oracle, in turn, could be made to substitute for a genie if we asked the oracle what the easiest way is to get certain commands executed. The oracle could give us step-by-step instructions for achieving the same result as a genie would produce, or it could even output the source code for a genie.