Given the context of the time (and even today) that scene has a big impact. Yes, because the girl is cute and we don't know much of her...she elicits sympathy. However, the fact that a black male character lives over the damsel who is a white....kind of buys into the entire Star Trek idea. I'm sure there can be articles or 'stuff' written about Rojan's choice, and if he did or didn't actually know who the cubes were. Furthermore, maybe he knew of Earth's past or maybe the 23rd century treatment of non-white human characters - if that still existed. Remember Sisko, even in the 24th century was still bothered by racism from Earth's past, hinting that there was possibly racism during his own time period.
We have to remember this episode is from the 1960s where black characters in films and television had a high mortality rate. Again, even today in films - especially horror films - the black or non-white characters are usually the ones to 'buy it' first or, at least, not make it to the end of the show. I recall being happy about Will Smith's Captain Steven Hiller being the hero in a summer blockbuster - and not dying - in Independence Day. So, while I feel for Julie Cobb's character, I think it's interesting who lived and who died. It's a very poignant Star Trek moment.
Of the roughly 60 or so casualties on TOS, limited to Enterprise
personnel and leaving out the six films, the only black character to perish----and the last, Stardate-wise----turned out to be Scott's assistant Watkins, from THAT WHICH SURVIVES.
Many redshirts actually survived their guest appearances, notably in the first season. In Season Two, thanks in part to THE APPLE, THE CHANGELING and OBSESSION, they were dropping like flies. BY ANY OTHER NAME is the rare ''either-or'' dilemma in which you'll get good and bad luck. But what makes this scene especially shocking is that ONLY the security guard gets out alive. The camera work sets up the cliche by seeming
to lead to it. So many will assume Shea has bought it, before the shock.