## Synopsys R&D Interview Question for Software Engineer / Developers

• 4

Country: India
Interview Type: Phone Interview

Comment hidden because of low score. Click to expand.
0
of 0 vote

what is the gaming pattern - round robin matches? or knock out? and to which level

Comment hidden because of low score. Click to expand.
0

knock outs

Comment hidden because of low score. Click to expand.
0
of 0 vote

A binary heap, with participants as leaves of the tree.
Split the two groups based on the ranking/seeding or whatever.
Eg: if n1,n2,..., n7,n8 are number according to ranking,
n1 is leaf in the first group and n2, the leaf in the second group
n3, n4 & so on...

The time complexity will be O(1) to find the winner and the runner.
Root of the heap is the winner.
The child element of the root, other than the winner is the runner up.

Comment hidden because of low score. Click to expand.
0

yes..i think u r correct

Comment hidden because of low score. Click to expand.
0

No. Wrong. O(n-1) for winner and o(n+logn-2) for runner. If you don't understand, search for selection trees in geekforgeeks

Comment hidden because of low score. Click to expand.
0

I guess MG is correct.. Selection tree will give the second ranked player not the runner up. Supposed the players are 1 ... 8 with 1 as lowest rank and 8 as highest rank.. suppose there is a match between 7 & 8 in the first round. and a match between 1 and 8 in the final.. and 8 wins.. MG's method will give runner up as 1 since 1 lost in final.. Selection tree will give answer as 7 since 7 is second highest ranked player...

Comment hidden because of low score. Click to expand.
0
of 0 vote

Linkedlist since any one can be removed at any time

Comment hidden because of low score. Click to expand.
0
of 0 vote

It can be a binary heap

Comment hidden because of low score. Click to expand.
0
of 0 vote

tournament trees or selection trees.

Comment hidden because of low score. Click to expand.
0

O(n) time to initialize the tree, O(1) to get the winner

Comment hidden because of low score. Click to expand.
0
of 0 vote

n1 n2 n3 n4 n5 n6 n7 n8

n1 n3 n5 n7

n1 n5

n1 ( winner)

can use max heap : who will match would be at root node so at the last winner to be at root
node .

Name:

Writing Code? Surround your code with {{{ and }}} to preserve whitespace.

### Books

is a comprehensive book on getting a job at a top tech company, while focuses on dev interviews and does this for PMs.

### Videos

CareerCup's interview videos give you a real-life look at technical interviews. In these unscripted videos, watch how other candidates handle tough questions and how the interviewer thinks about their performance.