|
---|
Replies are listed 'Best First'. | |
---|---|
Re: How do you view programming
by BrowserUk (Patriarch) on Feb 16, 2003 at 04:42 UTC | |
For me, coding(*) is neither art nor science nor engineering. Hopefully, that will remain the case at least until after I retire. As for all you youngsters out there...good luck:) Examine what is said, not who speaks. The 7th Rule of perl club is -- pearl clubs are easily damaged. Use a diamond club instead. | [reply] |
by Aristotle (Chancellor) on Feb 18, 2003 at 17:20 UTC | |
Without their invention, file systems that allowed useful designation of, and selection by, meta-data would do away with much of the nonsense that hierarchical directory structures cause.I think what you're asking for here is a database. BeOS actually does what you ask for; a pity that OS died at such a young age. Let's hope the open source thrust that is attempting to breath new life into it will succeed. Makeshifts last the longest. | [reply] |
by BrowserUk (Patriarch) on Feb 18, 2003 at 19:43 UTC | |
A database? Yes, in the generic sense of the term rather than any specific sense like RDBMS etc. I never encountered BeOS, but I did have passing flirtations with two other systems who's filesystems retained more information about a given dataset than just name/who/when/how big, namely PICK and MUMPS. Both also went to the great bit bucket in the sky although there are still small pockets of resistance clinging on to the use of both. Examine what is said, not who speaks. The 7th Rule of perl club is -- pearl clubs are easily damaged. Use a diamond club instead. | [reply] |
Re: How do you view programming
by steves (Curate) on Feb 16, 2003 at 00:58 UTC | |
Since the beginning, which is way too long ago now, I've always done most of it in my head during more mundane activities like driving the car, mowing the lawn or visting relatives -- oops I didn't say that, did I? It starts with ideas of "boxes" or "widgets" I want. That usually starts with an "I wish I could do this in one line idea" and goes from there. I always zoom in and out to the detail code level and back up to the overall design, usually many many times in my head before I write anything. Unless it's something very simple, or something that fits into an existing model I have. OO set me free here in a way, even though it was bit of a hump to learn it after 8-9 years of procedural coding. We had well defined, well accessed, well hidden data in our procedural code for the most part, but things in OO that you just couldn't do easily (or at all) procedurally, like inheritence and ploymorphism really made a difference. I find it comical that people sometimes scoff at Perl and OO because two of the things I love most and use a lot in my designs -- ties and closures -- don't exist in traditional OO languages like C++ and Java (or do they in Java and I don't know it?). And I simply can't live without regexps at this point in my life. Before Perl I did many years of shell, awk, and sed so I'm a lost cause when it comes to regexp's. During that thought time I scribble things down I usually can't make sense of later but which help me through the thoughts at the time. When I'm into it a bit I also usually write some throw-away test code to help solidify the ideas. I've never been a fan of the design first/code second method -- I just have to try things out or it gets too abstract. Having a full-time internet connection has really made a difference here. I can pop in and look up an idea or try a code snippet out whenever I want.I also like to try and find something at least similar to what I want that's already out there and check it out, both playing with it and looking at the code to see how other people solved similar problems. I've always felt I have more of a strength extending something someone else has started than coming up with extremely novel new ideas. For years I worked with a great idea guy and I just grabbed what he started and took it further. It was a very satisfying working relationship. It's not that I didn't come up with anything on my own -- he just was more of the frontier guy and I'd latch on and go for the ride. A few other quirks I know I have in this area: I need to see code blocks when I read and write code. I've never been able to see blocks with the old kernel style braces which is why I've almost never used them. To me, identifying code blocks is the first thing my brain tries to do when looking at code. When I code I invariably stub out a bunch of empty blocks and functions/methods first, then fill them in later (often breaking them down further). But contrast that with another quirk I've picked up in my old age: Line level comments primarily serve as a distraction, whereas I used to comment every line when I was right out of college. I think my brain has just learned to scan code over the years. An interesting observation here too: The absolute best coders and designers I've worked with are much better than their peers at "sucking in" existing code and making sense of it. That, IMO, is a much harder skill to master than writing brand new code and it is where much of our time is spent. | [reply] |
by iguanodon (Priest) on Feb 16, 2003 at 14:41 UTC | |
I've always done most of it in my head during more mundane activities like driving the car, mowing the lawn or visting relativesI get a good deal of work done this way. Once I get an idea of the data I'll be working with, I start thinking about the data structures I'll use within my application. I often find that this kind of design is easier to do when I'm not at my desk.
When I'm into it a bit I also usually write some throw-away test code to help solidify the ideas. I've never been a fan of the design first/code second method -- I just have to try things out or it gets too abstract. I've learned that in my job, the users often don't really know what they want, and they will agree to a paper specification without really reviewing it. I think a lot of people have a tough time visualizing the end product from some words and mocked up screens on paper. So I like to hack up a prototype application as soon as I get the basic requirements, then let the users comment on that. Not to mention that this increases the fun factor by minimizing the amount if spec. writing and maximizing the amount of coding. | [reply] |
Re: How do you view programming
by FoxtrotUniform (Prior) on Feb 16, 2003 at 00:27 UTC | |
I tend to think of programming as somewhat akin to proving theorems (which, despite the awful formal connotation, involves a lot of intuition) and writing non-fiction (which, despite the artsy connotation, involves a lot of structured thinking). Programming isn't even close to a well-defined, rigidly structured decision procedure; if it were, we'd get computers to do it. I approach programming the same way I approach writing, or proofs: I start by gathering information (doing research for a paper, taking stock of useful already-proven theorems in the field for a proof), then put that together into an outline of some sort, and finally assemble it into a working (hopefully) final form. Then I go back and edit the hell out of it. :-) I also tend to anthropomorphise my programs, subroutines, and constructs: See also Writing Habits. -- | [reply] [d/l] |
Re: How do you view programming
by simon.proctor (Vicar) on Feb 16, 2003 at 00:33 UTC | |
However, programming with Perl as left me with the idea that if the program is *hard to write* then I have the wrong datastructure or algorithm (usually both) and I'm shooting myself in the foot. Of the groupings you mentioned, because of the above I'd say I fell between science and art. After all, recognising why and how something is hard (or not) is an art yet the physical act of programming itself is more of an empirical science. To me at least. Because of that, I don't see variables as *variables* I visualise the thing they are doing on my behalf. In some cases (wierd as it may sound) I even think of them as sticky notes, post-it notes if you're from the UK :). I don't think, however, that if someone looked at my code they would necessarily see my 'programming personality' as I am forced to keep my code as structured and as clear as possible due to my working environment. I do the personality stuff for fun :). | [reply] |
Re: How do you view programming
by Ryszard (Priest) on Feb 16, 2003 at 08:13 UTC | |
How do you view your code building process? How do you view your data structures, design role, program flow, etc.I follow a couple of design rules: Where appropriate i seperate the business logic from the implementation specific detail from the presentation detail. Most of the perl i'm doing these days is around the web so this works really well with HTML::Template. At the end of the day we end up our own set of reusable modules/templates. In the guts of the apps I write, as a general rule each method will perform a single task, and the second i think "cut and paste" i start refactoring my design. (if i had thought about design more, i'd not need to do this, right?). We use quite a formal structure and set of design guidelines (eg for email you must use "this" module, and to interact with the database you must use "that" module, libraries must go "there" and templates must go "there"). While it may not be too everyones taste, my experience has shown to date, as our as our structure matures, the TTL for new apps is quite rapid, which makes the business happy.. :-) In terms of code specific detail, i dont use the deep magic of special vars and the like very often. I do however like to find new ways of doing things, so the balance between readible (junior level) code and "fun code" is sometimes hard to find in my professional life. In my personal life i'm left with quite often not enuff time to pursue the more complex options, so usually go for the easiest option to implement. Fortunately for me, the "easiest option" is a moving line. | [reply] |
Re: How do you view programming - On Naming Things
by Heidegger (Hermit) on Feb 17, 2003 at 07:11 UTC | |
...Taking raw/impure base items, purfiying until I am satisfied with each items state, pushing it all through a some process (whether simple or complex), and producing a new item, which is usually greater than the sum of the components... Let me refer to Plato's dialogue on language: Cratylus. What we do when we program is we name things. The question is whether things have the names assigned by nature beforehand or is it a matter of convention in naming things. We rediscover things through programming - give a name to a matter appearing from void. One might think that the names we give to things is conventional, but on the other hand we cannot call horse a cow, there is an idea of "a horse" and not a cow in the thing you're trying to name. Thus programming is a neverending flux, we talk programming words, name things. Give a thing it's true name and it will connect your mind to the nature of the thing and help you in your path. | [reply] |
Re: How do you view programming
by Mr. Muskrat (Canon) on Feb 17, 2003 at 14:51 UTC | |
How do you view your code building process? How do you view your data structures, design role, program flow, etc...? What is it like for you? Do you view variables as containers or simply some type of way to get your data back from the void which is memeory? | [reply] |
by l2kashe (Deacon) on Feb 17, 2003 at 18:35 UTC | |
Just trying to figure out where this came from, as it smacks of a Dilbertish type reponse to PHB. PHB: We need a Database server to increase productivity Dilbet: .o0( !!!! Does he know what he is talking about or is this a random statement !!! ) Dilbet: What color do you want the database to be PHB: I was thinking of a light blue.... You *did* see the sign about no fun in the monastary right :P /* And the Creator, against his better judgement, wrote man.c */ | [reply] |
by Mr. Muskrat (Canon) on Feb 17, 2003 at 18:50 UTC | |
It's semi-serious. It's easier to learn things when they have colors associated with them and colors have been shown to affect our moods. | [reply] |