Their thoughts raced. Who will rescue it? Will it fall?

It showed up around 3 p.m. and started pacing on a thin window ledge outside Ms. Donnelly-Coyne’s office. “He just seemed sweet and cute and very mellow,” she said in an interview on Wednesday.

Breaking out a window or sending down window cleaners would have been too risky, Ms. Donnelly-Coyne said, so officials baited live traps with cat food and placed them on the roof. They hoped the smell would lure the animal up another two floors.

Ms. Donnelly-Coyne stayed in the office until 9 p.m., taking breaks from her work to check on the raccoon. When she left, she said, the animal was curled up sleeping. “All they could do was put enough stinky food up there to encourage him to go up the last two floors,” she said. “We were all kind of worried he might be too tired to do so but thankfully the little guy kept going.”

The raccoon awoke around 10:30 p.m. and apparently had a change of heart. It started to descend, down to the 18th floor and then the 17th, before stopping on another ledge.

A photographer at Minnesota Public Radio zoomed in and saw the raccoon peering over the ledge. Maybe it saw the cheering crowd below. Maybe it thought the descent was too far. Either way, around 2 a.m. on Wednesday, it began another climb.

It surpassed the 18th floor and then 19th and kept going and going. Around 2:45 a.m., according to Mr. Nelson, it scaled the top and hopped onto the roof. It also found the cat food inside the trap.