Software Engineer Verser Interview Questions

664,898 software engineer verser interview questions shared by candidates

Implement a function string balanceParanthesis(string s); which given a string s consisting of some parenthesis returns a string s1 in which parenthesis are balanced and differences between s and s1 are minimum. Eg - "(ab(xy)u)2)" -> "(ab(xy)u)2" ")))(((" -> ""
avatar

Software Engineer

Interviewed at Meta

3.6
Aug 9, 2011

Implement a function string balanceParanthesis(string s); which given a string s consisting of some parenthesis returns a string s1 in which parenthesis are balanced and differences between s and s1 are minimum. Eg - "(ab(xy)u)2)" -> "(ab(xy)u)2" ")))(((" -> ""

class A { public A() { foo(); } public void foo() { System.out.println("Class A"); } } class B extends A { public B(){} public void foo() { System.out.println("Class B"); } } class main { public static void main(String[] args) { A a = new B(); } } What does it print? Class A or Class B?
avatar

Software Engineer

Interviewed at Bloomberg

4
Oct 25, 2012

class A { public A() { foo(); } public void foo() { System.out.println("Class A"); } } class B extends A { public B(){} public void foo() { System.out.println("Class B"); } } class main { public static void main(String[] args) { A a = new B(); } } What does it print? Class A or Class B?

You have datastructure my $users = [ { name => 'John', score => 10, }, { name => 'Bob', score => 1, }, { name => 'Carlos', score => 5 }, { name => 'Alice', score => 5, }, { name => 'Donald', score => 7 } ]; now u have to arrange the name with highest to lower score, if score is same than in alphabetical order #expected output: # John # Donald # Alice # Carlos # Bob
avatar

Perl Developer

Interviewed at Booking.com

4.1
Mar 24, 2014

You have datastructure my $users = [ { name => 'John', score => 10, }, { name => 'Bob', score => 1, }, { name => 'Carlos', score => 5 }, { name => 'Alice', score => 5, }, { name => 'Donald', score => 7 } ]; now u have to arrange the name with highest to lower score, if score is same than in alphabetical order #expected output: # John # Donald # Alice # Carlos # Bob

Write a function(int[]) -> int that returns the lowest unassigned integer. For example [] -> 1 (empty set), [1] -> 2, [5, 3, 1] -> 2. Basically just sort the array, iterate, and compare current and previous. If there is a gap then that's your number.
avatar

Software Engineer

Interviewed at Stripe

3.7
Oct 20, 2016

Write a function(int[]) -> int that returns the lowest unassigned integer. For example [] -> 1 (empty set), [1] -> 2, [5, 3, 1] -> 2. Basically just sort the array, iterate, and compare current and previous. If there is a gap then that's your number.

Viewing 81 - 90 interview questions

Glassdoor has 664,898 interview questions and reports from Software engineer verser interviews. Prepare for your interview. Get hired. Love your job.