|
Back when I was lecturing, I used to give a few marks for proper control naming. Effectively free marks. I repeatedly underscored this, but even so, out of the couple of hundred I lectured, probably only about 10 did it. Some even re-sat the test after I'd gone through the how I marked the original and still didn't shift themselves. Worse, you got the occasionalnon-functional code where it was clear they'd got confused where textBox12 was the user name and textBox13 was the forename and mucks-dipped the validation, but I couldn't give marks.
Quite an eye-opener.
|
|
|
|
|
I always wonder why people keep going in such a fashion. No matter how confused they get, no matter how much time they waste, they never take a step back and try to eliminate the cause of their problems.
In the end they deliver a complete mess and proudly proclaim that it works.
The language is JavaScript. that of Mordor, which I will not utter here
This is Javascript. If you put big wheels and a racing stripe on a golf cart, it's still a f***ing golf cart.
"I don't know, extraterrestrial?"
"You mean like from space?"
"No, from Canada."
|
|
|
|
|
CDP1802 wrote: In the end they deliver a complete mess and proudly proclaim that it works.
And this is precisely why working software should NOT be taken as the holy grail of measurements. Yes it may work, but it may be inefficient, difficult to maintain or extend, undocumented and show a complete lack of any form of design.
"There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult." - C.A.R. Hoare
Home | LinkedIn | Google+ | Twitter
|
|
|
|
|
You are preaching to the reverend.
The language is JavaScript. that of Mordor, which I will not utter here
This is Javascript. If you put big wheels and a racing stripe on a golf cart, it's still a f***ing golf cart.
"I don't know, extraterrestrial?"
"You mean like from space?"
"No, from Canada."
|
|
|
|
|
its a data grid for displaying users aged 18 and a text box to enter those aged 63 simple and clear
You cant outrun the world, but there is no harm in getting a head start
Real stupidity beats artificial intelligence every time.
|
|
|
|
|
...and if you click button42, then a MessageBox will show you the answer to life, the universe and everything...
Anything that is unrelated to elephants is irrelephant Anonymous ----- The problem with quotes on the internet is that you can never tell if they're genuine Winston Churchill, 1944 ----- I'd just like a chance to prove that money can't make me happy. Me, all the time
|
|
|
|
|
no that submits the question, everyone already knows the answer
You cant outrun the world, but there is no harm in getting a head start
Real stupidity beats artificial intelligence every time.
|
|
|
|
|
Quote: then a MessageBox will show
Surely you meant to say MessageBox4293 ?
|
|
|
|
|
A MessageBox isn't a control
|
|
|
|
|
What Nicholas said! Plus: "Don't call me Shirley!"
Anything that is unrelated to elephants is irrelephant Anonymous ----- The problem with quotes on the internet is that you can never tell if they're genuine Winston Churchill, 1944 ----- I'd just like a chance to prove that money can't make me happy. Me, all the time
|
|
|
|
|
I inherited an application just like that a while ago. Absolutely no attempt was made to rename the default control names, thus making the task of maintaining such a monstrosity extremely difficult.
Added to that, the developer also had no understanding of even the basics of OO as he had copied and pasted duplicate methods all over the code (clearly never heard of inheritance), had no structured exception handling and must rank as one of the worst applications I have seen.
And they wondered why they used to get constant complaints from the users about it
"There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult." - C.A.R. Hoare
Home | LinkedIn | Google+ | Twitter
|
|
|
|
|
I'm working on some code of my own creation. It involves retrieving similar (but not identical) data from about half a dozen databases. This data ibnolves medical clinics. Each database source has its own id/naming convention for clinics. Yesterday, I realized that I needed the department name under which each clinic operates. Instead of writing another stored proc to retrieve just this info, I completely ripped out all existing code for the individual data sources, and wrote a single stored proc that returns ALL of the data for a given clinic from all of the database sources, and then spent a couple of hours refactoring the code to use the new data. Benefit - I only have to retrieve the data one time when the app starts up instead of waiting until it's needed (and it WILL be needed). Everything became easier because the data is always available (in a static Globals class).
New programmers (as a rule) would rather code around the problem rather than address the problem directly. Granted, it can be difficult to know when optimizing the code is the right way to go, but still...
".45 ACP - because shooting twice is just silly" - JSOP, 2010 ----- You can never have too much ammo - unless you're swimming, or on fire. - JSOP, 2010 ----- When you pry the gun from my cold dead hands, be careful - the barrel will be very hot. - JSOP, 2013
|
|
|
|
|
Well, a "Master of Disaster" indeed (see his own response).
|
|
|
|
|
The problem is, you're assuming what the end result looks like from the names. If this is a Windows Forms app with multiple tabs, and each tab had a mix of textboxes and a grid, then it's entirely possible that it would look like this by default. It could be that they have created a data capture application that is driven by a wizard type interface.
Of course, having a decent naming convention would be a big start.
|
|
|
|
|
A uni lecturer told me of a colleague who had used various case spellings of "Fred" for variables in a Fortran program, which is just about as useful (stupid too). I suppose one could argue that one did it deliberately and one by being lazy, but I'd still say shoot them.
Life is like a s**t sandwich; the more bread you have, the less s**t you eat.
|
|
|
|
|
Quote: A uni lecturer told me of a colleague who had used various case spellings of "Fred" for variables in a Fortran program, which is just about as useful (stupid too). I suppose one could argue that one did it deliberately and one by being lazy, but I'd still say shoot them.
What? Fortran programmers?
You cant outrun the world, but there is no harm in getting a head start
Real stupidity beats artificial intelligence every time.
|
|
|
|
|
Heck no, just the ones called Fred.
Cobol programmers, on the other hand ....
Life is like a s**t sandwich; the more bread you have, the less s**t you eat.
|
|
|
|
|
I though they had died of old age (saying that I started as a Cobol programmer but managed to escape before it caught hold)
You cant outrun the world, but there is no harm in getting a head start
Real stupidity beats artificial intelligence every time.
|
|
|
|
|
are you looking at Lucy code? back in the day when I was a newbie programmer, I and a friend were assigned to work on a team with this russian gal named lucy. lucy wrote all her code with default names and to make it worse, she used the following for names for variables.
int var1, var2
string var3, var4, var5
double var6, var7
I am not making this up.
Some of the things we were doing were fairly complex. Her code usually compiled and she would brow beat(small shop and she was an angry russian) the installer to roll her code out.
IT never ever ever worked and then she would almost always be gone the next day on vacation/sick. I rewrote about 90% of it and would get in trouble for taking so much time.
It was not the most fun experience but at the time I really did not know any better. I did learn how to use the debugger quite well and how to set break points etc...
To this day I call this lucy code.
To err is human to really mess up you need a computer
|
|
|
|
|
sorry - was busy battening down the hatches ready for the cyclone expected in the morning,
Its a nerds mistake, being late (9)
Good luck!
PooperPig - Coming Soon
|
|
|
|
|
Tardiness!
"its a nerds" - mistake = anagram = Tardiness.
|
|
|
|
|
Damned!
Your time will come, if you let it be right.
|
|
|
|
|
+5 - first by a whisker!
Good luck tomorrow!
PooperPig - Coming Soon
|
|
|
|
|
"Tardiness" - anagram?
Your time will come, if you let it be right.
|
|
|
|
|
Sooooo Cloooooose (you got it right, of course - just missed winning by about 4 seconds!)
PooperPig - Coming Soon
|
|
|
|