Slashdot Mirror


Sophomore Uses List Context; Cops Interrogate

High school is bizarre enough, but a private high school is an environment uniquely removed from reality. S. and G., two sophomores at such a school in one of the United States' hot technology corridors, put up a couple of private websites with their unflattering thoughts about the school experience. Last week those sites got them suspended for two days. Worse -- because he wasn't familiar with the distinction between perl's scalar and list context, S. now has a police record. Update: 03/14 10:49 PM by J : We had some database trouble in the last couple hours, but all the comments seem to be back... whew.

These two 15-year-old friends are well-spoken; self-described geeks, they choose their words deliberately, with a minimum of "um." I'm using their initials instead of names because they don't want more trouble than they're already in. Their school has rules against disparaging its reputation, and they have learned their lesson from last week -- so you won't learn from me who they are, or which school it is they go to.

Let's get the code out of the way here, as a public service to students everywhere thinking about putting up a website of their own. Every perl expression has a context: scalar or list. (And for the rabid purists among you, who will flame me if I don't mention these, the other possible contexts are boolean, void, and interpolative.)

Many operators behave differently depending on context: in this case, the backtick. The statement:

my($f) = `fortune`;

...puts the backtick operator in list context, so it returns a list, where each element is one line from the program's output.

S. wants to be a developer when he graduates; he certainly has the most important thing down, which is to always be exploring and learning new things. In the process of converting his website from PHP to perl for no especially good reason, he wrote the above line.

If he had written the code correctly:

my $f = `fortune`;

...the backtick operator would have been in scalar context, assigned its complete result to $f for printing, and you wouldn't be reading this sad story.

Last week, the administrators at his school just happened to take a look at his webpage when fortune pulled up this quote:

I put the shotgun in an Adidas bag and padded it out with four pairs of tennis socks, not my style at all, but that was what I was aiming for: If they think you're crude, go technical; if they think you're technical, go crude. I'm a very technical boy. So I decided to get as crude as possible. These days, though, you have to be pretty technical before you can even aspire to crudeness.
- Johnny Mnemonic, by William Gibson

Because only the first line about the shotgun was stored in $f and shown on the webpage, it wasn't immediately obvious that this was a quote.

Visions of kids with shotguns in Adidas bags must have gone through someone's head. The school went into a sort of a crisis mode. Later they would mention that this wouldn't have been an issue if there hadn't been school shootings elsewhere in the country just a week prior.

The sophomores were called down to the office separately for questioning, one at a time, each of them without being told the other had been there. Each of them separately explained that fortune is a unix program that returns random quotations, and each of them told me that the administrators scoffed. "You're saying all these big companies that use unix, like Sun, have this fortune program?"

I assume the staff knew better and was just trying to find holes in the kids' stories, because apparently they had reloaded the page dozens of times and, of course, had gotten a new quote each time. After being released, G. got in touch with their Advanced Placement Computer Science teacher, who is, it sounds like, one of the few authority figures working for the Light Side of the Force. Her explanation of fortune was, finally, believed.

But the police had been called anyway, just to be on the safe side.

The suspension portion of the kids' punishment, carried out last Thursday and Friday, was actually over a separate website, one whose domain name contained the school's name and the Fword. This is a word, by the way, which G. obviously typed in to register the domain but which he was too polite to use over the phone. By the time we hung up, he had me embarrassed for saying it.

The site was very private, all things considered. He and S. had only told a few friends. And they'd done their homework, going over the referer logs to see who knew about it, and making sure the search engines didn't index it. They even banned the school's proxy by IP. As G.'s father later said, "it was the analogue of students in middle school passing a note back and forth. It was never meant to be in the public eye."

But it was disparaging of the school and it was, after all, a publicly available website. That's against the rules. The two shared joint responsibility, so they were both suspended.

Personally, I think a school's job is to teach not just the three R's, but also participation as a citizen in our Republic. That may be more important. For a school to teach freedom as a dry document while crushing student dissent is a waste.

It's legal, of course. The First Amendment doesn't apply to private schools. They can make whatever rules they want. Rules like theirs are great for raising robots. But anyone who's going to make a difference in this world is going to have to be comfortable with laughing at authority.

Unfortunately, the message the administration is sending gets heard. When I asked G. what he thought about being suspended for venting about his school, he told me he just didn't want to fight it. He said he might have felt differently a year ago, but now, "I don't know if it's from brainwashing or just not wanting to get expelled, but ... I just want it to be over." I can't blame him.

And S. said he understood the school's point of view. "People who were thinking about attending [his school] might see the site and think that they might not want to attend. ... I guess they do have reason for concern, because what if it shows up on a search engine."

S.'s family moved from Russia to the United States when he was four. His father painted for me an interesting picture of the interrogation by the police officers who were called to the school. Keep in mind that S. had already been told by his school that he fit the profile of a potential killer.

The police questioned them for a couple of hours. The "killer" profile was brought up again. Questions were raised about S.'s psychological state, whether he had made threats before, and whether the family had guns in the house.

His father repeated to me twice, as if he couldn't quite believe the whole thing had actually happened, that the police gave him a case number and are keeping the report on file. "I grew up in an environment," he told me, "where they are labeling people and where there is a witch hunt." He brought up McCarthyism. Eleven years in the States had led him to believe that this kind of thing doesn't happen here, or at least not anymore. I wish he were right.

The moral of the story is to be careful when passing notes to your friends. And believe the Camel when it says -- third edition, page 69 -- "You will be miserable until you learn the difference between scalar and list context."

4 of 404 comments (clear)

  1. Not the first bad Perl usage to bring the cops by merlyn · · Score: 5
    My ongoing legal case (documented for the most part at the Friends of Randal Schwartz site) involved a badly written port reflector, which I'm sad to say was embarassingly the first Perl code to be placed in the public record.

    Unfortunately, I had a much different outcome from this student. I'm still in the process of demonstrating that the law under which I was tried was constitutionally flawed, turning the activities of dozens of Oregonians every day into unwitting felonies.

  2. Sensationalism by micromoog · · Score: 5
    First, the main part of the headline (Perl) is not that big of a deal. The administrators saw a vague mention of loading shotguns into bags, and responded with alarm. This is not suprising given recent events, and the administration was entirely justified in doing this. Not to mention it's FUD to suggest the student has a "police record" because he was interrogated.

    Second, the case about the students being suspended for Web content . . . the story is missing the critical point, which is the content. This is a private organization we're talking about here; libel laws do apply. Tell me what the page said about the school, and then I'll make judgement.

    I guess I'm supposed to be outraged by this story, but I just have to assume the school was in the right until shown otherwise . . . they certainly were on the first point.

  3. To summarize.. by update() · · Score: 5
    After wading through Jamie's hyperventilating, the story is this:
    • These kids put up a fuck_theirschool.org site.
    • Because of a coding error, their page had the sentence "I put the shotgun in an Adidas bag and padded it out with four pairs" on it without making it clear that it's a quote from fortune, not part of their text.
    • The police investigated.
    • A lot of dumb grown-ups, whom we're going to laugh at aren't as up on Unix and Perl as Jamie. What morons!
    • The records of the investigation are still in the police files. There don't seem to have been any charges filed, despite Jamie's insinuations.
    I feel bad for these kids, but they just had some bad luck and things worked out the way they should have. Honestly, what is Jamie expecting? That the police will say, "Oh, a Perl error! We'll shred all the files and pretend this never happened?"

    Unsettling MOTD at my ISP.

  4. What did they expect ? by tmark · · Score: 5
    Many private schools have rules about the conduct of their students, especially as it affects the school or perceptions of the school itself. For instance, many schools have rules that their students *must* wear their school uniform while going or coming from the school; they cannot e.g. change in the school. So it should not come as a suprise that they would suspend students for (as I read the /. article) besmirching the school's reputation or policies.

    Nor should we be upset that they would enforce such a policy. Arbirary school rules are valid because they are private schools that students have elected to attend, and this very election constitutes tacit support of their policies. Private schools *try* to groom students in a very particular way (hence the uniforms, hence the common tradition of addressing students by last name, etc.) and this is precisely the reason parents send their children here. If the parents aren't happy with the school policies, they should not have sent them there. If you don't like the school's policies, don't send your kids there either.