Software Engineer Developer Interview Questions

466,911 software engineer developer interview questions shared by candidates

Given a single-line text string and a maximum width value, write the function 'string justify(string text, int maxWidth)' that formats the input text using full-justification, i.e., extra spaces on each line are equally distributed between the words; the first word on each line is flushed left and the last word on each line is flushed right.
avatar

Software Engineer - Applications

Interviewed at LinkedIn

3.8
Jul 31, 2012

Given a single-line text string and a maximum width value, write the function 'string justify(string text, int maxWidth)' that formats the input text using full-justification, i.e., extra spaces on each line are equally distributed between the words; the first word on each line is flushed left and the last word on each line is flushed right.

Imagine you have only two eggs and a 100 story building in front of you. Describe an algorithm (or technique) to minimize the number of throws (or tries) to determine where the egg will start to break when thrown off the building. If the egg breaks when thrown from that floor, it will always break from that floor or higher (i.e. all eggs have the same results per floor; they break or they don't).
avatar

Senior Software Engineer

Interviewed at Adobe

4.1
Mar 9, 2017

Imagine you have only two eggs and a 100 story building in front of you. Describe an algorithm (or technique) to minimize the number of throws (or tries) to determine where the egg will start to break when thrown off the building. If the egg breaks when thrown from that floor, it will always break from that floor or higher (i.e. all eggs have the same results per floor; they break or they don't).

Viewing 1351 - 1360 interview questions

See Interview Questions for Similar Jobs

Glassdoor has 466,911 interview questions and reports from Software engineer developer interviews. Prepare for your interview. Get hired. Love your job.