The Code Repeater
-
if (RegistryKeyExists()) {
/* 113 lines of code */
} else {
CreateRegistryKey();
/* Same 113 lines repeated here */
}What should we do with such "programmers"?
You could ask copy shops in the neighbourhood if they have a vacancy... ;P
-
You should commend them! Seriously, this is good work. If you consider that most people touching code are idiots, it's always good to duplicate code around, so that if someone messes up one copy, only a small part of your app gets broken, rather then the whole thing.
Jeroen De Dauw (blog | Twitter | Identi.ca)
I don't know if this is appropriate but it make sense
-
if (RegistryKeyExists()) {
/* 113 lines of code */
} else {
CreateRegistryKey();
/* Same 113 lines repeated here */
}What should we do with such "programmers"?
You dont have to do anything. eventually the employer will promote them to "managers"
-
You dont have to do anything. eventually the employer will promote them to "managers"
Sad but true.
Signature construction in progress. Sorry for the inconvenience.
-
You should commend them! Seriously, this is good work. If you consider that most people touching code are idiots, it's always good to duplicate code around, so that if someone messes up one copy, only a small part of your app gets broken, rather then the whole thing.
Jeroen De Dauw (blog | Twitter | Identi.ca)
-
if (RegistryKeyExists()) {
/* 113 lines of code */
} else {
CreateRegistryKey();
/* Same 113 lines repeated here */
}What should we do with such "programmers"?
Shameel wrote:
/* Same 113 lines repeated here */
I am sure you misread. There is probably one variable just slightly different which would completely justify the duplication :)
It's an OO world.
public class Naerling : Lazy<Person>{
public void DoWork(){ throw new NotImplementedException(); }
} -
Really? is this how you protect your code?
-
Shameel wrote:
/* Same 113 lines repeated here */
I am sure you misread. There is probably one variable just slightly different which would completely justify the duplication :)
It's an OO world.
public class Naerling : Lazy<Person>{
public void DoWork(){ throw new NotImplementedException(); }
} -
Shameel wrote:
/* Same 113 lines repeated here */
I am sure you misread. There is probably one variable just slightly different which would completely justify the duplication :)
It's an OO world.
public class Naerling : Lazy<Person>{
public void DoWork(){ throw new NotImplementedException(); }
}Yeah, probably some string value somewhere contains an
O
instead of a0
;) -
You dont have to do anything. eventually the employer will promote them to "managers"
However, once promoted to a manager they then make decisions on how all programmers should write their code. And they use their own code as a perfect example. Had one manager who refused to let any developer rewrite the systems that the manager had written!!!