+ 8

Interview question - Refactor or Leave it?

This is a question to all the devs who hire or interview. So I have an application that I wrote, which for my first proper project, is pretty big. I was learning as I wrote it. Whilst it functions exactly as I wanted it too, the code itself I know could be massively improved. In fact it did improve along the way, for example the first form is coded very differently to to the last one. including the actual form design. All the text boxes, comboboxes etc.. were all there but hidden and as the user adds new items it shows the next row. (this also limited the entries to 10 as there where no text boxes beyond that. In the latter forms they are added dynamically which removes the limitation of 10 entries. This will be my show piece for any interview I get so my question is. Should I refactor the whole project to the best of my current ability or leave it as it is so I can demonstrate the improvements as I got further into the project? Thanks Mike

23rd Aug 2019, 9:02 AM
Mike Hulme
Mike Hulme - avatar
12 odpowiedzi
+ 14
Mike Hulme i would like to refer you to this "ancient" article: https://www.joelonsoftware.com/2000/04/06/things-you-should-never-do-part-i/ It might enlighten you 😎
23rd Aug 2019, 10:23 AM
Burey
Burey - avatar
+ 5
My suggestion, you can try leave it for improvement, if there is no any improvement can do, then proceed to refactor. Both for refactor and leave have pros and cons. You have to evaluate which one it getting more easier and benefits more to proceed.
23rd Aug 2019, 9:31 AM
Uchiha Itachi
Uchiha Itachi - avatar
+ 5
They may see the improvements as you progress through your software. Because they want to see how you can improve and maintain your software well more than you create the software. Nowadays, mostly company will not create the new software , they probably will maintain and improve the current software unless there have any reason to do that.
23rd Aug 2019, 9:51 AM
Uchiha Itachi
Uchiha Itachi - avatar
+ 4
I think the decision to refactor has to be made after a cost/benefit analysis of the refactoring.
24th Aug 2019, 12:14 AM
Sonic
Sonic - avatar
+ 3
@Uchiha itachi The code in terms of usage is fine as the software will only be used by me. the question is more for interview purposes. Will the interviewer prefer to see my code at the best of my ability or will they like to see the improvements as I progressed though making software?
23rd Aug 2019, 9:46 AM
Mike Hulme
Mike Hulme - avatar
+ 3
Thanks, I don't actually have one yet, I am going to start applying once I have completed my MCSD Certification. I am just starting to think about interviews and how I will tackle them, hence the question. Thanks again for your help.
23rd Aug 2019, 10:18 AM
Mike Hulme
Mike Hulme - avatar
+ 2
Thanks, I will probably leave it as it is then, It also gives me some good talking points during the interview
23rd Aug 2019, 10:13 AM
Mike Hulme
Mike Hulme - avatar
+ 2
@Burey Thanks, that's a good read, I have fixed many bugs in it, so it makes sense to stick with the current code
23rd Aug 2019, 10:33 AM
Mike Hulme
Mike Hulme - avatar
+ 2
Thanks Jay
23rd Aug 2019, 11:47 AM
Mike Hulme
Mike Hulme - avatar
+ 1
Good Luck for your interview
23rd Aug 2019, 10:15 AM
Uchiha Itachi
Uchiha Itachi - avatar
0
Html
25th Aug 2019, 5:17 AM
zain albayati
zain albayati - avatar
0
enjoyed the article.
26th Aug 2019, 4:37 AM
Beatrice Prunotto
Beatrice Prunotto - avatar