homeGeek CultureWebstoreeCards!Forums!Joy of Tech!AY2K!webcam

Forum Home Post A Reply

my profile | directory login | | search | faq | forum home


» The Geek Culture Forums! » Other Geeky Stuff » Ask a Geek! » Discipline in Programming » Post A Reply


Post A Reply
Login Name:
Password (max 13 characters):
Message Icon: Icon 1     Icon 2     Icon 3     Icon 4     Icon 5     Icon 6     Icon 7    
Icon 8     Icon 9     Icon 10     Icon 11     Icon 12     Icon 13     Icon 14    
Message:

HTML is not enabled.
UBB Code™ is enabled.

 

Instant Graemlins Instant UBB Code™
Smile   Frown   Embarrassed   Big Grin   Wink   Razz  
Cool   Roll Eyes   Mad   Eek!   Confused   Happytears  
blush   Beard of Peter Gabriel!   crazy   tired   ohwell   evil  
shake head   cry baby   hearts   weep   devil wand   thumbsup  
thumbsdown   Geek   Applause   Angel   Envy    
Insert URL Hyperlink - UBB Code™   Insert Email Address - UBB Code™
Bold - UBB Code™   Italics - UBB Code™
Quote - UBB Code™   Code Tag - UBB Code™
List Start - UBB Code™   List Item - UBB Code™
List End - UBB Code™   Image - UBB Code™

What is UBB Code™?
Options


Disable Graemlins in this post.


 


T O P I C     R E V I E W
Groggle
Member # 2360
 - posted March 25, 2005 12:31
CSK posted a link to this article talking about scripting languages.

Reading it, I was struck by the "us versus them" of some of the interviewees. There was a real defensiveness on their part when they were comparing their favorite scripting language (Perl, Python, Ruby, PHP - whatever) with Java/C++/C# compiled languages.

Reflecting on that for a few moments, I found myself thinking about the code that I've seen written in both scripting and compiled environments. I've seen some truly amazing code written in both; similarly, I've bore witness to some truly awful code as well.

My sense is that the issue isn't choice of language, so much as clarity and discipline on the developer's part. From my experiences in software, 98% of what goes on in software boils down to 2 things: coupling and cohesion. If you get those right in your factoring of a problem, the resulting code should be reasonably readable.

I strikes me that perhaps our C/S (computer science) schools should be focusing on teaching not languages, but problem solving skills. Programming language choice should be a matter of "the right tool for the job", and is actually secondary to understanding how to break problem spaces into something coherent.

(Somewhere in the depths of my degree, I had Ada inflicted upon me, along with PL/1, Prolog, Lisp and a few other horrors. In truth, the languages turned out to be secondary to learning solid problem solving techniques.)
 
magefile
Member # 2918
 - posted March 25, 2005 14:22
quote:
Originally posted by Groggle:
I strikes me that perhaps our C/S (computer science) schools should be focusing on teaching not languages, but problem solving skills. Programming language choice should be a matter of "the right tool for the job", and is actually secondary to understanding how to break problem spaces into something coherent.

All the colleges I've visited in the past year or two (all of 'em in the top 10 for CS or engineering) have told me that their 100 courses are in Scheme or something similar for exactly that reason. It's not until you start doing OS design or assembly that they give you a "real-world" language.
 
csk
Member # 1941
 - posted March 25, 2005 19:35
In other words, someone's skill in IT has little to do with what development environment they are currently acquainted with. Give them a little time, and they'll transfer the really important skills (like problem solving, etc) to another environment. In addition, once they're familiar with several, they can objectively evaluate the suitability of each for a particular task. Now, if only the people recruiting for IT jobs realised the above, life would be much easier. Still, it happens, as I moved successfully from a mainframe PL/1 etc based job to one mainly coding C/C++ on Unix. I've also done Windows coding, and a fair bit of sysadmin type stuff.

However, I think the defensiveness seen in the article is as a result of the sort of narrow minded thinking you're talking about. People thinking of scripting languages as "toys", etc. In my opinion, you should program at the highest level that is machine efficient enough to successfully implement what you're doing. In other words, use one of those very high level languages for the bulk of the work. Unfortunately many people don't see a blanket decision to always use C/C++/whatever as the premature optimisation that it is.
 
Groggle
Member # 2360
 - posted March 26, 2005 11:11
CSK - Precisely the point.

Unfortunately that logic applies all over the place. I was at a job interview relatively recently where the interviewers turned it into a "do you know all of the trivia about Java" session.

I'm sitting there thinking to myself "you don't get it, do you?". What they were looking for was someone who had "married Java". I wasn't exactly impressed by them (not to mention the fact that they seemed oblivious to the fact that in an interview, I'm evaluating them, too)
 
GameMaster
Member # 1173
 - posted March 26, 2005 12:01
quote:
csk:In my opinion, you should program at the highest level that is machine efficient enough to successfully implement what you're doing. In other words, use one of those very high level languages for the bulk of the work. Unfortunately many people don't see a blanket decision to always use C/C++/whatever as the premature optimisation that it is.
Don't you mean the lowest level that is human efficient enough... Every level your removed from the chip is another level of compilation or interpretation which is (generally) added overhead.

I'm of the school of thought that the best tool for the job. Granted I reach for Java or C++ more often than scripting languages, but that is because I see C++ as being closer to the chip and JAVA as being a universal tool wrench, I can run the same compiled versions on my laptop (Mac), my home computer (Linux), school (Solaris) and work (Linux)....

Our school really trys to teach the ideas about programing (though most classes are in C+). Then they cover a few other languages (Lisp is covered in intro to AI and Natural Language processes sing; ML, Prolog and a brief intro to Java is covered in Program Languages concepts; Operating Systems is programming in C (POSIT stuff) and VC++ (windows system calls provided by the windows API); Graphics is done in VC+++; there are elective classes for Fortran, VB and a few others; and Object Oriented programming is either C++ or Java depending on who you take it with).

Personally, I've always wanted there to be a class in problem solving, flow charting, ML diagramming and just thinking like a programmer. Tutoring I see a lot of the same types of mistakes. Most people who I've seen struggling with programming either can't see "the forest" and they get to caught up "in the trees" (loose sight of the details); or all they see "the forest" and don't see "the trees" and can't find where the first tree is (loose sight of the details). If there isn't a semesters worth there, then fill the rest with computer history and/or truth tables and logical proof. Just my crazy idea.
 
The Famous Druid
Member # 1769
 - posted March 26, 2005 13:57
quote:
Originally posted by GameMaster:
quote:
csk:In my opinion, you should program at the highest level that is machine efficient enough to successfully implement what you're doing. In other words, use one of those very high level languages for the bulk of the work. Unfortunately many people don't see a blanket decision to always use C/C++/whatever as the premature optimisation that it is.
Don't you mean the lowest level that is human efficient enough... Every level your removed from the chip is another level of compilation or interpretation which is (generally) added overhead.

Depending on the situation, you're both right.

The aim should be to minimise the cost of obtaining a satisfactory solution.

For quite some time now, the cost of hardware has been dropping. As faster hardware gets cheaper, the balance has been shifting from hand optimisation and clever coding tricks towards 'brute force' and higher-level languages.

That said, if you're coding for embedded systems (as I often do) and the end product will ship in the tens of millions, then it may make sense to spend $100,000 in programmer time to solve some problem rather than adding a 10 cent part to every unit you ship.

As GM said, it's all about using the right tool for the job.

(techno-trivia: Did you know that over half the microprocessors manufactured are 4-bit or less?)
 
quantumfluff
Member # 450
 - posted March 26, 2005 14:39
With few exceptions, the further away you are from the chip the better. We should be always using the language that expresses intent in the closest possible way to the problem domain. I've been writing code for 30 years and I've yet to see proof that more than 10 to 20 percent of all programmers out there understand memory allocation well enough to be allowed to do it.

What I've been doing a lot of lately is splitting languages in mid-application. I'll write the classes I need in Java or C++, then wrap them in tcl. Then I write as much of the application logic in tcl. This helps me maintain the wall between what I want to do, and the elements I have to do it with. Even better, it let's me split my team. I can have the senior guys writing the performance oriented stuff in one language, and another group writing in a language where they can't get into pointer problems.

But there's more...
- I can rapid prototype a new feature in tcl much faster than I can write it in C .If it runs too slow, I can recode in C *after* I get the logic right.
- I can deliver customer specific modifications to the scripted part.
- I can write unit tests for the C code in the scripting language.

It's a win all around.
 




Contact Us | Geek Culture Home Page

© 2018 Geek Culture

Powered by Infopop Corporation
UBB.classicTM 6.4.0



homeGeek CultureWebstoreeCards!Forums!Joy of Tech!AY2K!webcam