Yeah but assignment operators are cheap…

Coding Horror is often fun, and a good read, particularly for aspiring techies who want an inside glimpse of some of the details that would make up your life if you pursue that path. But when I read Jeff’s post on spaces versus tabs in code formatting I both cracked up and immediately thought of one of my Data Structures students who has to reformat any piece of code he is given before he starts working with it. With my students deep into their team projects, I wonder if they are running into the conflict that Jeff claims is inevitable:

The only programming project with no disagreement whatsoever on code formatting is the one you work on alone. Wherever there are two programmers working on the same project, there are invariably disagreements about how the code should be formatted. Sometimes serious disagreements. The more programmers you add, the more divisive those disagreements get. And handling those disagreements can be .. tricky.

He goes on to discuss the pitfall of team members taking it upon themselves to “fix” each other’s code – not just spacing, but even variable name conventions and the like. It may seem odd that such computationally trivial decisions (I mean, we all know the compiler doesn’t care…) could cause so much interpersonal strife on a team. But if you’ve ever really gotten into programming, the idea that someone else might be messing around with your code, after you get it how you like it….. well, it is probably at least a little agitating. And Jeff cites the classic “The Elements of Programming Style” to illustrate that these style principles actually do matter when it comes to code as a tool for comprehension and communication. Which is particularly key on a team project.

In their book called The Elements of Programming Style, Kernighan and Plauger also identify what we would call discourse rules. Our empirical results put teeth into these rules: It is not merely a matter of aesthetics that programs should be written in a particular style. Rather there is a psychological basis for writing programs in a conventional manner: programmers have strong expectations that other programmers will follow these discourse rules. If the rules are violated, then the utility afforded by the expectations that programmers have built up over time is effectively nullified.

I am now curious to see how my students navigate this problem – if they try to get consistency or not, and if the most obsessive person in the group just wins (I fear I have one group with people who don’t care that much and one group with people who do). And it makes me think about the style guidelines I set out for code in my introductory class, and that perhaps sharing some of this research would make it clearer why I have those standards.

My Body My Data

Medical databases are one of the huge trends in IT right now, and there are a lot of people looking at how to make national, integrated personal medical information databases a reality. There are also a lot of people looking at the special requirements for accuracy and privacy when building such databases. I like this person’s comments, from a patient’s perspective, on the importance of sharing ownership of the records with the patient. The comments were triggered by someone commenting that they signed up for Google Health and found it to be a combination of inaccurate and with troubling omissions – basically, a health record that would likely be worse than nothing. The system is still in beta, but it is troubling to see partial data being provided by hospitals/pharmacies, as compared to simply declining to provide information unless it is complete. Even if this is improved, as it likely would be before it left beta and hopefully before any doctor relied on it as a source of medical information, the conversation about participation in the data collection and maintenance is a good one. It is troubling that any doctor would be wary of a patient seeing their own lab results, though perhaps they would like to be able to ensure that they are presented with enough context to be meaningful. But I think we have to insist that information about ourselves and our health is our information, and just as we have a right to see what is in our credit report and who has been looking at it, and a process for correcting it if necessary, we have a right to the same control over our health records. Given the nature of the information, I think we also need a system more effective than the current credit history system, and we ought to have it in place before these systems are widely adopted.

Don’t discount the crossword puzzle in all this

Maybe the most interesting thing about this summary of responses to questions about the future of newspapers by a variety of newspaper and media experts is that they all urge newspapers to be very hesitant about reducing their number of print days per week, but they also concur that in ten years we will no longer have daily print newspapers. Common wisdom is that, at some point in the not too distant future, newspapers are going to have to leave their bulky physical form behind, but it seems that these experts think it is more important now to start reshaping the content and format than the frequency or delivery mechanism. It is also clear that the current model for newspaper success hinges on not alienating those who are still reading the newspaper more than attracting new readers.
This dovetails nicely with an article I read earlier in the week about proposed legislation to allow newspapers to go non-profit so long as they do not endorse political candidates, in order to help them survive. This legislation, it is acknowledged, is intended to help small community newspapers more than the larger newspapers that seem to be the focus of the discussion above. Allowing newspapers to choose to operate under the same non-profit umbrella as public broadcasting is intriguing – I suspect that the public broadcasting rules in part reflect the limited spectrum issues in radio and television and the merit of using some of them towards non-commercial purposes. It is intriguing to consider whether there has now been a flop, with digitization removing the spectrum issues for radio and television, but the increased presence of free, electronic sources of information putting a de facto cap on the amount of print media our economy can support.

But can I trade my morning coffee for a dinner glass of wine?

I find this visualization of how the choices we make can reduce water consumption odd, if not downright problematic in places. The graphic seems to be an odd mix of “here are some things that you might do” with a tinge of “here is your complete usage in a day” – if it was the former, why would they include flushing the toilet and washing your hands twice. But if it is the later, well, they are suggesting you need only do those things twice in an entire day – this seems improbable and/or unhygienic. But it is the assessment of food that seems really bizarre. At breakfast, you are urged to have cereal instead of eggs, but at dinner, you are encouraged to not eat the bread (requiring the same amount of water as the cereal) and replace it with a potato. Even more bizarre, you are recommended to replace your apple with an orange that required five gallons less water. This seems to reflect a lack of perspective on the scale of some of these numbers. Based on the chart, the single largest impact thing you can do to save water is to stop eating meat, particularly beef. The impact of this is large enough that if the way you motivate yourself to do this is that you can eat whatever fruits/veggies/grains you like, it is still a significant gain. On the other hand, if you intend to still eat beef, while some of the other choices they show may be worth pursuing, you probably shouldn’t bother worrying about whether you are eating an apple or an orange. Particularly if you start taking into account that water consumption isn’t the only environmental factor people worry about – my apple may require more water, but it may also be grown a couple of miles down the road from me and require significantly less transportation.

Getting this weblog back on track…

I love Dinosaur Comics – I find it similar to xkcd (also written by a computer scientist/computational linguist!), and I have to resist the temptation to link to every single one. But anybody who took my intersession course on figurative language has got to check out the March 9th one on conceptual metaphor; trust me if you remember the Lakoff and Turner readings this one will crack you up. For everybody else, try the comic about plagiarism, which makes me laugh out loud every time I read it. If you read both you might notice they look similar – which, yes, every strip uses the same art with just the text changed up. Oh, and if you want to get everything out of Dinosaur Comics, make sure you not only read the title, but also the mouseover/alt text AND the subject line autofilled for the “comments” link for the entry.

Who doesn’t love a little Zapf Chancery sometimes?

I like the discussion here about an article finding that font choice influences how likely someone is to act on material they are reading. It is pointed out in the comments that the appropriate interpretation is not that Arial is the best font, but that cutesy fonts that get used to add interest or make documents look more “friendly” may actually be reducing the impact of the document. I have seen studies about reading comprehension based on font choice, but this is the first I have seen that talks about how likely a person is to take a particular action based on the font used in the document encouraging them to take that action (here, to go exercise).

Where is my bus?

RouteShout is a new service being piloted in Pittsburgh (but available for purchase to any city) that lets riders text a number posted on a bus stop and get texted back the arrival time of the next buses scheduled to reach that stop. [via Pittsburgh Metblogs] I love how simple and yet useful this idea seems. They don’t seem to be trying to solve the entire “where is my bus” question – you can’t go to a website and see maps of all the buses, you can’t send complex queries about fares or what transfers are needed to get from here to there. But if what you want to know is when the next bus is coming, you get that information quickly and easily using technology that many people already have in their pocket. Even with the ability to check a website on my phone, I think I would prefer using this service because it just seems so streamlined. The DeepLocal company that has developed this service also seems like a pretty interesting group; they appear to have developed a number of these very minimal-function, minimal-interface systems.

I want allllll my apps

From earlier this week, a report that Windows is producing a limited version of Windows 7 that will be cheaper and faster for netbooks to run. The big difference being discussed? You can run a maximum of three applications at a time….

The company claims most users wouldn’t be affected by the three-app limit. “We ran a study which suggested that the average consumer has open just over two applications [at any time],” Painell claims. “We would expect the limit of three applications wouldn’t affect very many people.”
However, Microsoft told journalists at last year’s Professional Developers Conference that 70% of Windows users have between eight and 15 windows open at any one time. “That’s probably talking across all users,” Painell says. “That’s talking across enterprise and business as well, which is a very different segment.”

I would love to see that study, just to know how they measured “applications”. I have seen elsewhere mention that antivirus software will not count, but what about other background processes like network monitoring tools? How is this being counted? If I pull up the calculator, does that count against me or is that just part of the OS?
Also, who were these users and what were they doing with their computers while being monitored? I absolutely grant that much of my computer usage falls in the high-usage category and thus Microsoft would be perfectly happy expecting me to use the more powerful (and expensive) version of their OS. But right now, I’m sitting on my sofa with a cup of coffee (okay – half coffee half hot chocolate) reading my email while doing some web surfing (and writing this) and looking over the assignment I wrote yesterday to catch any final typos. That is three applications right there before you count that I have my IM client open and one of my emails I just read had a pdf attached to it.
This is the part where not being an OS expert could be the problem, but I also have a hard time seeing how capping the number of apps leads to a more efficient operating system. Is the idea that the OS would run intolerably slow on a netbook with more than three apps going so users are just being kept from putting themselves in a context that will make the OS look bad? Or are there games that you can play with simplifying your caching algorithms or processor allocation that work if you are capped at three apps but fail when you have the possibility of twelve apps to deal with? Basically – is the cap just a cap, or does the cap enable them to actually change the way that the OS works in order to get efficiency advantages?

Google has some self-esteem issues

It seems that either Google has been hacked or its security settings have been upgraded to be excessively paranoid. It will be interesting to hear what ended up happening to produce these results….

Bored at work?

Make yourself hallucinate, chemical free! I just have two questions? Who was laying around taping half ping pong balls over their eyes while listening to static? And, on the more science-y side, I wonder if, even if these are chemical-free ways too mess with your brain, there could be lasting side effects of doing these types of things repeatedly? How often would you have to rub a friend’s nose before you permanently felt like your own nose was super long?