Software Engineer Sr Interview Questions

71,535 software engineer sr interview questions shared by candidates

2. /** * A tournament tree is a binary tree * where the parent is the minimum of the two children. * Given a tournament tree find the second minimum value in the tree. * A node in the tree will always have 2 or 0 children. * Also all leaves will have distinct and unique values. * 2 * / \ * 2 3 * / \ | \ * 4 2 5 3 * * In this given tree the answer is 3. */ class Node { Integer value; Node left, right; Node(Integer value, Node left, Node right) { this.value = value; this.left = left; this.right = right; } } class Solution { /** * This should return the second minimum * int value in the given tournament tree */ public static Integer secondMin(Node root) { } }
avatar

Senior Software Engineer

Interviewed at LinkedIn

3.8
Apr 5, 2017

2. /** * A tournament tree is a binary tree * where the parent is the minimum of the two children. * Given a tournament tree find the second minimum value in the tree. * A node in the tree will always have 2 or 0 children. * Also all leaves will have distinct and unique values. * 2 * / \ * 2 3 * / \ | \ * 4 2 5 3 * * In this given tree the answer is 3. */ class Node { Integer value; Node left, right; Node(Integer value, Node left, Node right) { this.value = value; this.left = left; this.right = right; } } class Solution { /** * This should return the second minimum * int value in the given tournament tree */ public static Integer secondMin(Node root) { } }

Viewing 111 - 120 interview questions

Glassdoor has 71,535 interview questions and reports from Software engineer sr interviews. Prepare for your interview. Get hired. Love your job.