Gotham’s penultimate episode delivered a satisfying conclusion to the arc of main protagonist, Jim Gordon - next on the agenda is the Batman himself. Gotham’s fifth and final season is confirmed to end with an episode largely set in the future, giving a glimpse at the show’s characters at a more familiar point in the Batman story.

As such, the second-to-last episode “They Did What?” was Gotham’s final opportunity to wrap up all the plot threads in the main timeline and bring everyone’s overall story to a fitting end. Vitally, this meant reaching an endpoint for Ben McKenzie’s Jim Gordon. While much of the focus surrounding Gotham’s finale has centered around Batman himself, Gordon remains the show’s lead protagonist and has undergone significant character development over the past five seasons.

With only two episodes left, however, Gordon’s story was finally provided some much-needed resolution ahead of next week’s Bat-centric final installment. And that makes the finale a considerably more unexpected proposition.

Gotham may be rapidly hurtling towards an ending, but its interpretation of Jim Gordon still had plenty left to do prior to the show’s penultimate offering. Firstly, there’s the issue of rank. Gordon is obviously best known to Batman fans as the city’s Commissioner  - the sometimes useful, sometimes hapless leader of Gotham’s police department that strikes up a fruitful working relationship with the local vigilantes. Throughout its time on television, one of Gotham’s main functions has been to track Gordon’ path through the GCPD to his position at the head of law enforcement and accordingly, it only makes sense that part of the show’s ending would involve Jim finally attaining the rank most closely associated with his character.

Some might argue that this scene should have been Gotham’s very final moment, but the increasing focus on Bruce Wayne and Batman in recent seasons relegated Jim’s promotion to the second-to-last episode instead. Nevertheless, Gordon’s long-awaited rise to Commissioner brought his story as the Gotham City cop struggling to bring fairness and justice to a corrupt department to a feel-good close.

Of course, Gotham didn’t just chronicle Jim’s professional life, but also his personal and romantic tribulations. Gordon’s commitment to crime-fighting caught up to his domestic life on more than one occasion, as exes became villains and new loves were kidnapped repeatedly. These more personal storylines were also neatly tied off in “They Did What?” and Gordon, against all odds, seemingly managed to find true love with Lee Thompkins, whilst also enjoying a mutually respectful relationship with the mother of his child (the future Batgirl), Barbara Kean.

With everything right in the world of Jim Gordon, Gotham is now moving to finalize the transformation of Bruce Wayne into Batman. Young Bruce has been steadily evolving into his future superhero persona throughout Gotham’s tenure and shown rapid growth in the past two seasons in particular. Prior to the show’s most recent episode, however, he was still missing two sizeable Bat-ingredients: the reasoning behind the Bat motif and an explanation as to why he chooses to work outside of the law despite his strong relationship to Gordon and the GCPD.

“They Did What?” attempted to provide answers on both accounts. Bruce’s use of a device that summoned bats to defeat Bane set-up his adoption of the animal’s image further down the line and, although it may not be the most convincing reasoning, it does at least provide a basis for his obsession with the flying mammals later in life. The episode also featured scenes of Bruce contemplating his part in Gotham’s misery, questioning whether his high-profile name indirectly led to the rise of No Man’s Land, as the likes of Jeremiah and Ra’s al Ghul had targeted him personally. This thinking explains why the youngster dons a mask for his later crime-fighting escapades. The episode ends with Bruce jetting away from Gotham City, similar to Christian Bale’s version of the character at the start of Batman Begins.

All that’s left for Gotham now is to bring those elements together and round off Bruce’s transformation into Batman with a reveal that many viewers have been anticipating for quite some time.

More: Gotham Twist Brings Season 5 Even Closer To The Dark Knight Rises

Gotham season 5 concludes with “The Beginning…” April 25th on Fox.