Software engineer ii Interview Questions in San Jose, CA | Glassdoor

Software engineer ii Interview Questions in San Jose, CA

98

software engineer ii interview questions shared by candidates

Top Interview Questions

Sort: RelevancePopular Date

You are given a predefined function which generates random number from 1 to 5. You need to use this function and create another function which will generate random number from 1 to 7. Now most important thing is to remember that new random function should be even (i.e. the number generated should be unpredictable, and evenly spaced out).

4 Answers

If the function returns float or double: - Simply multiply the answer by 7/5. If the function returns integers: - Call the rand5 function 7 times, sum the results, calculate mod7 of the sum and finally add 1.

Let f() be the random function that returns a number between (1,5). Let g() = f() -1; then g is a function that returns a number between (0,4). Let h() = g()/4; then h is a function that returns a number between (0,1). Let i() = h()*6; then i is a function that returns a number between (0,6) Let j() = i() + 1; then j is a function that returns a number between (1,7). important to note that simply multiplying by 7/5 is NOT correct. If you do that you can never get 1 out of your random number . the numbers you will obtain in that case will be uniformly distributed between (7/5 and 7) not between (1,7)

One or more comments have been removed.
Please see our Community Guidelines or Terms of Service for more information.

Create bunch of Api for project in 4-6 hours.

4 Answers

an algoritm question that I don't recall at the moment

2 Answers

Basic puzzles like i) given two buckets of 4 and 7 liters.. how can you get 5 liters. ii) some sorting and searching algo questions

2 Answers

Difference between variable hiding and shadowing

2 Answers

Talk about yourself. Difference between string buffer and string builder, difference between string and String buffer. Leet code Coding example.

3 Answers

One or more comments have been removed.
Please see our Community Guidelines or Terms of Service for more information.

Layer 2 and Layer 3 protocols

1 Answer

CRUD operations of MongoDB and why MongoDB over other DBs?

1 Answer

Why doesn't eBay use EJBs, Hibernate, Spring, Transactions?

2 Answers

One or more comments have been removed.
Please see our Community Guidelines or Terms of Service for more information.

Write an algorithm to find out the price for a keyword of an item based on the values present in the existing tables. He gave me 2 tables and some columns with item details. Keywords to search for those items etc.. The keywords can have multiple words. For example if you have existing high volume keywords in the the table like iPOD with a certain price then how much price should be the phrase "iPOD Touch 8gb" (a potential low volume keyword).

1 Answer