Blog

Estimation/Planning Fallacy

Our very dear customer has a nice article published, dedicated to  Planning Fallacy. As software developers we constantly struggling it here so this article does really ring a bell for us. Please find short version here, for the full version go to original post, for definition of a problem please read the wiki article.

Tags: 

Weekly Puzzle#3: Problem solving

Write a program, solving problem below in any new for you language:

There are 1000 lockers in a high school with 1000 students. The
problem begins with the first student opening all 1000 lockers; next
the second student closes lockers 2,4,6,8,10 and so on to locker 1000;
the third student changes the state (opens lockers closed, closes
lockers open) on lockers 3,6,9,12,15 and so on; the fourth student

Tags: 

Weekly Puzzle#2: Guess, what this code does?

Can you guess what this code in Swift does?

func secretFunction(of num: Int) -> Int {
if num == 1 {
return 1
} else {
return num * secretFunction(of:num - 1)
}
}

And what result would you see for the code below:
let x = 4
let result = secretFunction(of: x)
?

Tags: 

Weekly Puzzle#1: Guess, what this code does?

No copy-past and compilation, please! Try to understand, what this Java code does just reading it. Be honest with yourself, cheaters die along :)

// Java program to print ***
public class Secret
{
public static void main(String[] args)
{
String str = "ABC";
int n = str.length();
Secret secret = new Secret();
secret.doYourDance(str, 0, n-1);
}

Tags: 

Using try-with-resource statement working with BufferedReader in Java

Working with BufferedReader and it's variants in Java was always a bit of a pain: developers need to not to forget close it and do the IOException handing doing it, not to mention about bunch of null-checks. Otherwise you program work could be interrupted with the most surprising and unpleasant way possible.
Prior the Java 7 we had to do smth. like this:

String readFirstLineFromFileWithFinallyBlock(String path)
Tags: 

Android P at the First Glance

Android 9 (Pie) available for developer preview! We've spent some time playing around and this is what we've found out.

Tags: