The Artima Developer Community
Sponsored Link

Java Buzz Forum
Can Code be Green? Does Beauty Matter? from PeopleOverProcess.com

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Michael Cote

Posts: 10306
Nickname: bushwald
Registered: May, 2003

Cote is a programmer in Austin, Texas.
Can Code be Green? Does Beauty Matter? from PeopleOverProcess.com Posted: Feb 12, 2008 12:46 PM
Reply to this message Reply

This post originated from an RSS feed registered with Java Buzz by Michael Cote.
Original Post: Can Code be Green? Does Beauty Matter? from PeopleOverProcess.com
Feed Title: Cote's Weblog: Coding, Austin, etc.
Feed URL: https://cote.io/feed/
Feed Description: Using Java to get to the ideal state.
Latest Java Buzz Posts
Latest Java Buzz Posts by Michael Cote
Latest Posts From Cote's Weblog: Coding, Austin, etc.

Advertisement

At an IBM green event, James asks:

On that note I am beginning to wonder if beautiful code is green code. Code generation tends to generate pretty ugly code - but is it less efficient? Developers that write beautiful code may end up in great demand for their green coding: but this is pure conjecture at this point…

Tragically, I don’t think there’s a great deal of corelation between beauty of code and it’s greenness. The more beautiful code is, typically, the further away it is from machine language, assembly, and other “low level languages.” My assumption would be that converting the beautiful code down to that layer takes extra energy. Thus, the most energy efficient code would probably be assembly (I don’t think we would expect people to write in machine code).

How Much Energy Does Beauty Take?

It’s like: is a manual screwdriver or an electric, cordless drill/screwdriver more green? Human labor seems more green at first, but maybe it takes a whole apple of energy for a person to turn a screw, and just 1/4 of an apple for a cordless drill to do it. I just apples here as some unit of energy.

Then again, you could say, all of the time it took to write in assembly instead of higher level languages - including re-learning and new people picking it up - uses more energy.

But, the fact that it seems like you could go either way means to me that “beautiful code” is less than a sure shot for green.

The Problem with Beautiful Code

Also, it should be noted that “beauty” in code is highly subjective, even more so than hardware. Beautiful code to an Ada developer is crap to a Java developer is utter madness to a ruby coder. JavaScript can look magnificnet to an Ajax developer, but a hard-core Java develoepr will disagree with the dynamic nature of JavaScript so much that it will look like ass all the time.

More generally, we’ve tried to establish “beauty” and “health” in code for decades which - as we should sort of expect with a properly functioning 20th century mind - just sets up the new traditions that the next rebels will break to get software language innovation. If beauty is maximum configuration with XML, along comes rails with the new beauty.

Disclaimer: IBM is a client, as is Sun.

Technorati Tags:

Read: Can Code be Green? Does Beauty Matter? from PeopleOverProcess.com

Topic: Google Analytics: How To Locate Tracking for Existing Website / Profile Previous Topic   Next Topic Topic: OpenID for Intranets and Extranets

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use