tb
BAN USER
Comments (11)
Reputation 0
Page:
1
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
0
of 0 vote
Assumption: Any new customer id is added at the place such that the list remains sorted.
Soln: Start with newIndex and oldIndex on the new and old files.
while(newIndex < LENGHT_LOGFILE2 && oldIndex < LENGTH_LOGFILE1)
{
if(new(newIndex) == old(oldIndex))
{
newIndex++; oldIndex++;
}
else if (new(newIndex) > old(oldIndex))
{
print(old(oldIndex));
oldIndex++;
}
else
{
newIndex++;
}
}
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Page:
1
CareerCup is the world's biggest and best source for software engineering interview preparation. See all our resources.
In general, you are suggesting the use of bitsets.
- tb April 27, 2008