Click here to Skip to main content
11,644,731 members (69,503 online)

Welcome to the Lounge

   

For lazing about and discussing anything in a software developer's life that takes your fancy except programming questions.

Technical discussions are encouraged, but click here to ask your programming question.

The Lounge is rated PG. If you're about to post something you wouldn't want your kid sister to read then don't post it. No flame wars, no abusive conduct, no programming questions and please don't post ads.
 
GeneralRe: MQOTD Pin
TheCardinal19-Oct-12 0:53
memberTheCardinal19-Oct-12 0:53 
GeneralRe: MQOTD Pin
V.19-Oct-12 1:03
memberV.19-Oct-12 1:03 
GeneralRe: MQOTD Pin
TheCardinal19-Oct-12 6:25
memberTheCardinal19-Oct-12 6:25 
GeneralRe: MQOTD Pin
charlieg19-Oct-12 5:55
membercharlieg19-Oct-12 5:55 
GeneralWhy do candidates give complicated solutions to simple problems? Pin
Amarnath S18-Oct-12 21:26
memberAmarnath S18-Oct-12 21:26 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Ranjan.D18-Oct-12 21:37
memberRanjan.D18-Oct-12 21:37 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Rajesh R Subramanian18-Oct-12 21:41
memberRajesh R Subramanian18-Oct-12 21:41 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Jan Steyn18-Oct-12 22:41
memberJan Steyn18-Oct-12 22:41 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Norm .net18-Oct-12 21:42
groupNorm .net18-Oct-12 21:42 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Ranjan.D18-Oct-12 21:46
memberRanjan.D18-Oct-12 21:46 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Norm .net18-Oct-12 23:04
groupNorm .net18-Oct-12 23:04 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
V.18-Oct-12 21:51
memberV.18-Oct-12 21:51 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Rajesh R Subramanian18-Oct-12 21:57
memberRajesh R Subramanian18-Oct-12 21:57 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
peterchen18-Oct-12 21:51
memberpeterchen18-Oct-12 21:51 
Amarnath S wrote:
Some candidates want to store all numbers in an array, then sort that array, and get the largest two numbers


That's the immediate solution that comes to mind, I'd do this unless it's performance criticial (it takes a while before a std::sort<int> becomes notably slower than a linear search)), because it's just one line of code. Scales well with "we also need the smalles ones", "today, the top 5".

Database - that's the immediate solution if they are already stored in a database.

These candidates are not bad. Your questions might not be precise enough.

This is actually a good thing: you can differentiate between candidates who draw their own conclusions, and those that ask for clarification / confirmation.
It is an indicator of the candidates non-code skills, but not a fault per se.




Let them present their solution, see if they can follow through (I'd expect at least the select statement, a reference to a standard sort algorithm, or the description of an sort algorithm and how they'd implement it, respectively). Then ask for a more specific solution: "Can you do that without an array, reading the numbers from the console?"

Note that jsut asking "Can you do that without an array" may have candidates stumped what your intentions are - and that's not useful. You don't want "lightbulb" answers, you want them talking about code.

GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Rajesh R Subramanian18-Oct-12 22:01
memberRajesh R Subramanian18-Oct-12 22:01 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
peterchen18-Oct-12 23:05
memberpeterchen18-Oct-12 23:05 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Rajesh R Subramanian19-Oct-12 18:22
memberRajesh R Subramanian19-Oct-12 18:22 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
jschell19-Oct-12 10:13
memberjschell19-Oct-12 10:13 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Rajesh R Subramanian19-Oct-12 18:31
memberRajesh R Subramanian19-Oct-12 18:31 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
jschell20-Oct-12 4:39
memberjschell20-Oct-12 4:39 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Amarnath S18-Oct-12 22:03
memberAmarnath S18-Oct-12 22:03 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
V.18-Oct-12 21:56
memberV.18-Oct-12 21:56 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Amarnath S18-Oct-12 22:20
memberAmarnath S18-Oct-12 22:20 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
jschell19-Oct-12 10:20
memberjschell19-Oct-12 10:20 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
_Josh_18-Oct-12 22:16
member_Josh_18-Oct-12 22:16 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Mark Wallace18-Oct-12 22:44
memberMark Wallace18-Oct-12 22:44 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
BobJanova18-Oct-12 23:23
memberBobJanova18-Oct-12 23:23 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Amarnath S18-Oct-12 23:42
memberAmarnath S18-Oct-12 23:42 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
BobJanova19-Oct-12 1:05
memberBobJanova19-Oct-12 1:05 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Guirec Le Bars18-Oct-12 23:43
memberGuirec Le Bars18-Oct-12 23:43 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Amarnath S18-Oct-12 23:49
memberAmarnath S18-Oct-12 23:49 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Guirec Le Bars18-Oct-12 23:52
memberGuirec Le Bars18-Oct-12 23:52 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Amarnath S18-Oct-12 23:54
memberAmarnath S18-Oct-12 23:54 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Guirec Le Bars18-Oct-12 23:56
memberGuirec Le Bars18-Oct-12 23:56 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Amarnath S19-Oct-12 0:03
memberAmarnath S19-Oct-12 0:03 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
_Maxxx_18-Oct-12 23:53
member_Maxxx_18-Oct-12 23:53 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
jschell19-Oct-12 10:24
memberjschell19-Oct-12 10:24 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
jim lahey19-Oct-12 0:44
memberjim lahey19-Oct-12 0:44 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
Andy Brummer19-Oct-12 1:53
sitebuilderAndy Brummer19-Oct-12 1:53 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
wizardzz19-Oct-12 4:25
memberwizardzz19-Oct-12 4:25 
GeneralRe: Why do candidates give complicated solutions to simple problems? Pin
jschell19-Oct-12 10:08
memberjschell19-Oct-12 10:08 
QuestionWindows API Pin
PaulowniaK18-Oct-12 19:48
memberPaulowniaK18-Oct-12 19:48 
AnswerRe: Windows API Pin
AlexCode18-Oct-12 20:45
memberAlexCode18-Oct-12 20:45 
AnswerRe: Windows API Pin
GenJerDan19-Oct-12 3:36
memberGenJerDan19-Oct-12 3:36 
GeneralRe: Windows API Pin
PaulowniaK21-Oct-12 14:31
memberPaulowniaK21-Oct-12 14:31 
GeneralInstalling A Doggie Door Pin
Roger Wright18-Oct-12 18:24
memberRoger Wright18-Oct-12 18:24 
GeneralRe: Installing A Doggie Door Pin
Andy_L_J18-Oct-12 18:42
memberAndy_L_J18-Oct-12 18:42 
GeneralRe: Installing A Doggie Door Pin
OriginalGriff18-Oct-12 21:13
mvpOriginalGriff18-Oct-12 21:13 
GeneralRe: Installing A Doggie Door Pin
Espen Harlinn18-Oct-12 21:53
mvpEspen Harlinn18-Oct-12 21:53 
GeneralRe: Installing A Doggie Door Pin
OriginalGriff18-Oct-12 21:58
mvpOriginalGriff18-Oct-12 21:58 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web03 | 2.8.150731.1 | Last Updated 3 Aug 2015
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid