<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
		>
<channel>
	<title>Comments on: Google Phone Interview (Part 1)</title>
	<atom:link href="http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/feed/" rel="self" type="application/rss+xml" />
	<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/</link>
	<description>Why am I fighting to live, if I am living to die ?</description>
	<lastBuildDate>Thu, 12 Nov 2009 22:54:29 +0000</lastBuildDate>
	<generator>http://wordpress.com/</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: jhon</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-28377</link>
		<dc:creator>jhon</dc:creator>
		<pubDate>Fri, 26 Jun 2009 00:41:43 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-28377</guid>
		<description>Hi,
     I had my interview with Google for associate product manager .. you can read the interview here

http://ferozeh.com/Interviews/Google/google.php

hope it is useful to others..</description>
		<content:encoded><![CDATA[<p>Hi,<br />
     I had my interview with Google for associate product manager .. you can read the interview here</p>
<p><a href="http://ferozeh.com/Interviews/Google/google.php" rel="nofollow">http://ferozeh.com/Interviews/Google/google.php</a></p>
<p>hope it is useful to others..</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Naren</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-27812</link>
		<dc:creator>Naren</dc:creator>
		<pubDate>Wed, 28 Jan 2009 07:50:18 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-27812</guid>
		<description>Hi, I&#039;m T. Naren from India. I&#039;m pursuing PG diploma in IT. I want to do MS(IT) and then I want to join in Google. Could you please tell me how to prepare for the Technical round. If possible tell me what kind of questions they will ask.
Thank you.</description>
		<content:encoded><![CDATA[<p>Hi, I&#8217;m T. Naren from India. I&#8217;m pursuing PG diploma in IT. I want to do MS(IT) and then I want to join in Google. Could you please tell me how to prepare for the Technical round. If possible tell me what kind of questions they will ask.<br />
Thank you.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Cmonkey</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-25306</link>
		<dc:creator>Cmonkey</dc:creator>
		<pubDate>Wed, 27 Feb 2008 18:05:00 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-25306</guid>
		<description>The coin denomination solution that you&#039;ve posted isn&#039;t correct...
here is a better version:
http://cmonkeyfreeware.blogspot.com/2008/02/coin-denomination-problem.html</description>
		<content:encoded><![CDATA[<p>The coin denomination solution that you&#8217;ve posted isn&#8217;t correct&#8230;<br />
here is a better version:<br />
<a href="http://cmonkeyfreeware.blogspot.com/2008/02/coin-denomination-problem.html" rel="nofollow">http://cmonkeyfreeware.blogspot.com/2008/02/coin-denomination-problem.html</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: One Fab Fit Mom - Weight Loss Success! &#187; Want to interview at Google? Check out these unbelievable&#8230;</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-24863</link>
		<dc:creator>One Fab Fit Mom - Weight Loss Success! &#187; Want to interview at Google? Check out these unbelievable&#8230;</dc:creator>
		<pubDate>Wed, 23 Jan 2008 22:18:41 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-24863</guid>
		<description>[...] http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/ [...]</description>
		<content:encoded><![CDATA[<p>[...] <a href="http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/" rel="nofollow">http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/</a> [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Marcus</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-23716</link>
		<dc:creator>Marcus</dc:creator>
		<pubDate>Sat, 17 Nov 2007 14:35:42 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-23716</guid>
		<description>You cant run though both lists at the same time cause there are not ordered.</description>
		<content:encoded><![CDATA[<p>You cant run though both lists at the same time cause there are not ordered.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tanay</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-21558</link>
		<dc:creator>tanay</dc:creator>
		<pubDate>Mon, 10 Sep 2007 14:14:52 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-21558</guid>
		<description>plz tell me what do they ask on telefone ....i have applied for soft. engg., as a fresher graduate.</description>
		<content:encoded><![CDATA[<p>plz tell me what do they ask on telefone &#8230;.i have applied for soft. engg., as a fresher graduate.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Michael</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-21315</link>
		<dc:creator>Michael</dc:creator>
		<pubDate>Mon, 03 Sep 2007 12:38:42 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-21315</guid>
		<description>Yeah - can&#039;t edit.

The answer is, assuming the integers are sorted, to walk them at the same time:
List l1, l2;
List ans = /*new List*/;
byte toInc=3; /*Bitmask*/
int lastRead1;
int lastRead2;
for (int pos1=0,pos2=1,n1=l1.size(), n2=l2.size(); pos1 &lt; n1 &amp;&amp; pos2 &lt; n2; ) {
if ((1&amp;toInc) != 0) {
lastRead1 = l1[pos1++];
}
if ((2&amp;toInc) != 0) {
lastRead2 = l2[pos2++];
}
if (lastRead1 == lastRead2) {
ans.push(lastRead1);
toInc=3;
} else if (lastRead1 &lt; lastRead2) {
toInc=1;
} else {
  toInc=2;
}
}
return ans;
}

Probably better to only store offsets into an existing list too and to count backwards if order is not important.</description>
		<content:encoded><![CDATA[<p>Yeah &#8211; can&#8217;t edit.</p>
<p>The answer is, assuming the integers are sorted, to walk them at the same time:<br />
List l1, l2;<br />
List ans = /*new List*/;<br />
byte toInc=3; /*Bitmask*/<br />
int lastRead1;<br />
int lastRead2;<br />
for (int pos1=0,pos2=1,n1=l1.size(), n2=l2.size(); pos1 &lt; n1 &amp;&amp; pos2 &lt; n2; ) {<br />
if ((1&amp;toInc) != 0) {<br />
lastRead1 = l1[pos1++];<br />
}<br />
if ((2&amp;toInc) != 0) {<br />
lastRead2 = l2[pos2++];<br />
}<br />
if (lastRead1 == lastRead2) {<br />
ans.push(lastRead1);<br />
toInc=3;<br />
} else if (lastRead1 &lt; lastRead2) {<br />
toInc=1;<br />
} else {<br />
  toInc=2;<br />
}<br />
}<br />
return ans;<br />
}</p>
<p>Probably better to only store offsets into an existing list too and to count backwards if order is not important.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Michael</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-21314</link>
		<dc:creator>Michael</dc:creator>
		<pubDate>Mon, 03 Sep 2007 12:37:35 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-21314</guid>
		<description>The answer is, assuming the integers are sorted, to walk them at the same time:
List l1, l2;
List ans = /*new List*/;
byte toInc=3;   /*Bitmask*/
int lastRead1;
int lastRead2;
for (int pos1=0,pos2=1,n1=l1.size(), n2=l2.size(); pos1 &lt; n1 &amp;&amp; pos2 &lt; n2; ) {
  if ((1&amp;toInc) != 0) {
    lastRead1 = l1[pos1++];
  }
  if ((2&amp;toInc) != 0) {
    lastRead2 = l2[pos2++];
  }
  if (lastRead1 == lastRead2) {
    ans.push(lastRead1);
    toInc=3;
  } else if (lastRead1 &lt; lastRead2) {
    toInc=1;
  } else {</description>
		<content:encoded><![CDATA[<p>The answer is, assuming the integers are sorted, to walk them at the same time:<br />
List l1, l2;<br />
List ans = /*new List*/;<br />
byte toInc=3;   /*Bitmask*/<br />
int lastRead1;<br />
int lastRead2;<br />
for (int pos1=0,pos2=1,n1=l1.size(), n2=l2.size(); pos1 &lt; n1 &amp;&amp; pos2 &lt; n2; ) {<br />
  if ((1&amp;toInc) != 0) {<br />
    lastRead1 = l1[pos1++];<br />
  }<br />
  if ((2&amp;toInc) != 0) {<br />
    lastRead2 = l2[pos2++];<br />
  }<br />
  if (lastRead1 == lastRead2) {<br />
    ans.push(lastRead1);<br />
    toInc=3;<br />
  } else if (lastRead1 &lt; lastRead2) {<br />
    toInc=1;<br />
  } else {</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: ntrphanikumar</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-8545</link>
		<dc:creator>ntrphanikumar</dc:creator>
		<pubDate>Thu, 03 May 2007 05:17:15 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-8545</guid>
		<description>hi is the answer to hash???</description>
		<content:encoded><![CDATA[<p>hi is the answer to hash???</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Lee</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-8512</link>
		<dc:creator>Lee</dc:creator>
		<pubDate>Wed, 02 May 2007 12:43:41 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-8512</guid>
		<description>Thanks for this post. Many interview questions can be found at http://www.technical-interview.com</description>
		<content:encoded><![CDATA[<p>Thanks for this post. Many interview questions can be found at <a href="http://www.technical-interview.com" rel="nofollow">http://www.technical-interview.com</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: ThanhSon</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-4573</link>
		<dc:creator>ThanhSon</dc:creator>
		<pubDate>Sat, 07 Apr 2007 00:06:06 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-4573</guid>
		<description>isn&#039;t the problem equal to: given two lists of integers (document id). find the ids that appear in both lists. ?</description>
		<content:encoded><![CDATA[<p>isn&#8217;t the problem equal to: given two lists of integers (document id). find the ids that appear in both lists. ?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Muhammad Rizwan Asghar</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-3371</link>
		<dc:creator>Muhammad Rizwan Asghar</dc:creator>
		<pubDate>Wed, 21 Mar 2007 07:13:01 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-3371</guid>
		<description>It is reply to raster&#039;s comment.

I think raster is wrong to conclude the complexity O(n1). It may be O(n2) if Saeed has more docs than that of Haroon. So, O(n1+n2) represent the complexity in a right way.</description>
		<content:encoded><![CDATA[<p>It is reply to raster&#8217;s comment.</p>
<p>I think raster is wrong to conclude the complexity O(n1). It may be O(n2) if Saeed has more docs than that of Haroon. So, O(n1+n2) represent the complexity in a right way.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: raster</title>
		<link>http://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-1394</link>
		<dc:creator>raster</dc:creator>
		<pubDate>Sat, 06 Jan 2007 09:19:05 +0000</pubDate>
		<guid isPermaLink="false">https://haroonsaeed.wordpress.com/2006/07/17/google-phone-interview-part-1-2/#comment-1394</guid>
		<description>If you iterate through the list of docs containing &quot;Haroon&quot; and generated a subset of docs which  has &quot;Saeed&quot; in it, you will get the list of docs containing both &quot;Haroon&quot; and &quot;Saeed&quot;. Thats O(n1). Does that sound right?</description>
		<content:encoded><![CDATA[<p>If you iterate through the list of docs containing &#8220;Haroon&#8221; and generated a subset of docs which  has &#8220;Saeed&#8221; in it, you will get the list of docs containing both &#8220;Haroon&#8221; and &#8220;Saeed&#8221;. Thats O(n1). Does that sound right?</p>
]]></content:encoded>
	</item>
</channel>
</rss>
