Today's Question:  What does your personal desk look like?        GIVE A SHOUT

 ALL


  A boolean value interview question

Someone asked a question on StackOverflow, he was asked an interview question. The question is : Given 3 boolean variables a, b, c, return true if at least 2 out of the 3 are true. He gave the solution as follows :boolean atLeastTwo(boolean a, boolean b, boolean c) {    if ((a && b) || (b && c) || (a && c)) {        return true;    } else {        return false;    }}Then the interviewer asked him to improve the solution given and ma...

6,581 0       RETURN EXPRESSION BOOL CONDITIONAL


  GUI vs CLI: Operation vs Expression

Consider this user interface for a car:The goal of these interfaces is to make you operate something, and operate it efficiently and safely. The grooves and clicks and limits constrain the range of motion and the number of choices. The visual look heavily hints at how to actively use it. They are usually not hard to learn. More importantly, the learning curve plateaus. Once you learn how to drive a car, there’s not much progression after that. Boundedness is an important property of these interfaces, by design.Now look at this “user interface” f...

2,055 0       PROGRAMMER IDE GUI CLI OPERATION EXPRESSION