BETA CAE Systems Interview Question

On the coding task one, problem was to find the bug.