Developer Program Engineer Interview Questions
- 0of 0 votes
Answersremove duplicates from a sorted linked list
- Anonymous July 02, 2011| Report Duplicate | Flag | PURGE
Motorola Developer Program Engineer Algorithm - 0of 0 votes
AnswersMemory management in PHP
- Girlie June 29, 2011| Report Duplicate | Flag | PURGE
Google Developer Program Engineer PHP - 0of 0 votes
AnswerPass by value and pass by reference in PHP
- Girlie June 29, 2011| Report Duplicate | Flag | PURGE
Google Developer Program Engineer PHP - 0of 0 votes
Answersyou are given following:
- Anonymous June 21, 2011
1. An empty tank
2. Unlimited source of water.
3. Some container of certain measurments and a container of 1 litre is always given.
Your job is to fill the tank from source of water using the containers in minimum number of steps.
You cant fill the container with a small amount of water than its size (filling partially is not allowed).
Find the number of steps and print the solution.
e.g.
Tank Size: 80 litre
Containers: 1,3,5,6,25 litre
Solution:
4
5,25,25,25
Tank Size: 71 litre
Containers: 1,3,5,6,25 litre
Solution:
6
3,6,6,6,25,25| Report Duplicate | Flag | PURGE
Google Developer Program Engineer Algorithm - 0of 0 votes
Answersdefine class such that you can make object of this class on a heap but not on the stack.
- Anonymous June 20, 2011| Report Duplicate | Flag | PURGE
Goldman Sachs Developer Program Engineer C++ - 0of 0 votes
Answersdefine a class such that you can make object of this class but you can not inherit this class.
- Anonymous June 20, 2011| Report Duplicate | Flag | PURGE
Goldman Sachs Developer Program Engineer C++ - 0of 0 votes
Answers) If you have class B which inherits from class A, the two values printed below might be different. Why?
- Gone June 01, 2011
B *myPointer = new B();
A *myOtherPointer = myPointer;
printf(“%x”, myPointer);
printf(“%x”, myOtherPointer);| Report Duplicate | Flag | PURGE
Developer Program Engineer - 0of 0 votes
AnswersWhy doesn’t this work?
- Gone June 01, 2011
#include <iostream>
#include <string.h>
using namespace std;
void newBuffer(char* outBuffer, size_t sz) {
outBuffer = new char[sz];
}
int main(void) {
const char* kung = "KUNG";
char* foo;
size_t len = strlen(kung);
newBuffer(foo, len);
memset(foo, 0, len+1);
strncpy(foo, kung, len);
cout << foo << endl;
return 0;
}| Report Duplicate | Flag | PURGE
Developer Program Engineer - 1of 1 vote
AnswersConsider a series in which 8 teams are participating. each team plays twice with all other teams. 4 of them will go to the semi final.How many matches should a team win, so that it will ensure that it will go to semi finals.?
- putta.sreenivas May 11, 2011| Report Duplicate | Flag | PURGE
Amazon Google Developer Program Engineer Software Engineer / Developer Algorithm Brain Teasers - 0of 0 votes
AnswersGiven a set of numbers eg:{2,3,6,7,8} . any one who is playing the game can score points only from this set using the numbers in that set. given a number, print all the possible ways of scoring that many points. Repetition of combinations are not allowed.
- putta.sreenivas May 09, 2011
eg:
1. 6 points can be scored as
6
3+3
2+2+2
2. 7 can be scored as
7
2+2+3
but 2+3+2 and 3+2+2 is not allowed as they are repetitions of 2+2+3| Report Duplicate | Flag | PURGE
Amazon Developer Program Engineer Algorithm - 0of 0 votes
AnswersWhat are the different types of cast in C++? Difference between static, dynamic, reinterpret cast.
- Nupur April 28, 2011| Report Duplicate | Flag | PURGE
Goldman Sachs Developer Program Engineer C++ - 0of 0 votes
AnswersDetect loop in a linked list. What is its complexity. Optimize it to O(n).
- Nupur April 28, 2011| Report Duplicate | Flag | PURGE
Goldman Sachs Developer Program Engineer Algorithm - 0of 0 votes
AnswersDifference between pointer and reference. Can a NULL pointer be used as a reference?
- Nupur April 28, 2011| Report Duplicate | Flag | PURGE
Goldman Sachs Developer Program Engineer C++ - 0of 0 votes
AnswersYou have a Word Processor type Program. There are 2^16 fonts. Each font is associated with a 4MB geometric instruction set. This is written in a flat file.
- Nupur April 28, 2011
Everytime a user selects a font this file is searched linearly. Develop a program to optimize the font search. (You could either add some functionality improvement in the word processor application while font selection or in the font search file).| Report Duplicate | Flag | PURGE
Goldman Sachs Developer Program Engineer Algorithm - 0of 0 votes
Answersprinting, deleting linked list and some more questions on linked list, accesing time of binary search
- Bhari April 18, 2011| Report Duplicate | Flag | PURGE
Samsung Developer Program Engineer Data Structures - 0of 0 votes
AnswersFormatting was incorrect so posted again.
Consider the given structure:
struct node
{
int data;
struct node *next;
struct node *next_larger;
}
You are given a list where each node is of type defined above. Initially all the next larger pointer of each node points to NULL. Write an algorithm to update the next larger pointer of each so that they point to immediate next largest node in the list.
e.g.
- Riya April 17, 20114-------->8------->2------->1------->9 |->NULL |->NULL |->NULL |->NULL |->NULL Output: |------------------| V |--------!-----------------V 4-------->8------->2------->1------->9 |---------^ ^--------| |--->NULL
| Report Duplicate | Flag | PURGE
Adobe Developer Program Engineer - 0of 0 votes
AnswersWhat is the size of a class which will have only one function declaration as public. And what is the size of a class if that the same function is declared as virtual.
- viswathsen April 10, 2011class Myclass { public: int fun(); }; Sizeof(Myclass) ?? And class Myclass { public: vitual int fun(); }; Sizeof(Myclass) ??
| Report Duplicate | Flag | PURGE
IBM Developer Program Engineer C++ - 0of 0 votes
AnswersWrite an algorithm that finds the contiguous subsequence of elements in an array with largest sum. The elements in the array can be negative.
- Ajai March 27, 2011
Is there a O(n) solution for it? Any good solutions are very much appreciated.| Report Duplicate | Flag | PURGE
Adobe Developer Program Engineer Algorithm - 0of 0 votes
AnswersDo anyone know about ION Trading, Noida ? How is the company/ job security /appraisals ? Thanks in advance..
- Hello.. Need info please.. Thanks March 25, 2011| Report Duplicate | Flag | PURGE
ION Trading Developer Program Engineer - 0of 0 votes
Answersvoid main()
- vimal March 17, 2011
{
int i=0;
int array[5];
for(i=0;i<=5;i++)
array[i]=0;
printf("why this printf not working?");
}| Report Duplicate | Flag | PURGE
Nexabion Developer Program Engineer C - 0of 0 votes
AnswersI know that String is declared as a final class in Java, so we can't extend the class. Than how we are able to use methods from String class like toString(), equals() etc, because they are non final methods.
- JavaJavas March 06, 2011| Report Duplicate | Flag | PURGE
Developer Program Engineer Java - 0of 0 votes
Answersconvert a binary tree to binary search tree inplace. We cant use any extra space.
- Abhilash H February 22, 2011| Report Duplicate | Flag | PURGE
Google Developer Program Engineer Algorithm