[algogeeks] Re: find numbers whose difference is min

2011-08-16 Thread Dave
@Shuaib: It will work in all cases. If you don't think so, give a
counterexample.

Dave

On Aug 16, 12:50 am, Shuaib aries.shu...@gmail.com wrote:
 That will work but not in all cases as radix sort isn't a generalized sorting 
 algorithm, is it? :)

 --
 Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/

 On 16-Aug-2011, at 10:10 AM, Dave dave_and_da...@juno.com wrote:



  @Shuaib: You could sort the numbers in O(n) with a radix sort, and
  then finding the min is easy. Mind you, the radix sort might be slower
  than an O(n log n) sort, but still it satisfies the O(n) constraint.

  Dave

  On Aug 15, 8:41 pm, Shuaib aries.shu...@gmail.com wrote:
  That won't work. And I don't think an O(n) solution is possible.

  --
  Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/

  On 16-Aug-2011, at 6:25 AM, sukran dhawan sukrandha...@gmail.com wrote:

  find the minimum of two numbers in a loop o(n) and subtract the two

  On Tue, Aug 16, 2011 at 6:13 AM, Brijesh Upadhyay 
  brijeshupadhyay...@gmail.com wrote:
  Algorithm to find the two numbers whose difference is minimum among the 
  set of numbers. For example the sequence is 5, 13, 7, 0, 10, 20, 1, 15, 
  4, 19 The algorithm should return min diff = 20-19 = 1. Constraint - Time 
  Complexity O(N)

  --
  You received this message because you are subscribed to the Google Groups 
  Algorithm Geeks group.
  To view this discussion on the web 
  visithttps://groups.google.com/d/msg/algogeeks/-/U8gTWUISJn8J.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to 
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group 
  athttp://groups.google.com/group/algogeeks?hl=en.

  --
  You received this message because you are subscribed to the Google Groups 
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to 
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group 
  athttp://groups.google.com/group/algogeeks?hl=en.

  --
  You received this message because you are subscribed to the Google Groups 
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to 
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group 
  athttp://groups.google.com/group/algogeeks?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: How to solve this problem

2011-08-16 Thread Dave
@Ankur: The least significant digit of a[i], base n, is a[i]%n. The
middle digit is (a[i]/n)%n, and the most signficant digit is a[i]/
(n*n). So the code looks something like

int b[n], c[n], i, j;
for( i = 0 ; i  n ; ++i ) // sort by least significant digit
c[i] = 0;
for( i = 0 ; i  n ; ++i )
c[a[i]%n]++;
c[n-1] = n - c[n-1];
for( i = n-2 ; i = 0 ; --i )
c[i] = c[i+1] - c[i];
for ( i = 0 ; i  0 ; ++i )
b[c[a[i]%n]++] = a[i];

for( i = 0 ; i  n ; ++i ) // sort by middle digit
c[i] = 0;
for( i = 0 ; i  n ; ++i )
c[(b[i]/n)%n]++;
c[n-1] = n - c[n-1];
for( i = n-2 ; i = 0 ; --i )
c[i] = c[i+1] - c[i];
for ( i = 0 ; i  0 ; ++i )
a[c[(b[i]/n)%n]++] = b[i];

for( i = 0 ; i  n ; ++i ) // sort by most significant digit
c[i] = 0;
for( i = 0 ; i  n ; ++i )
c[a[i]/(n*n)]++;
c[n-1] = n - c[n-1];
for( i = n-2 ; i = 0 ; --i )
c[i] = c[i+1] - c[i];
for ( i = 0 ; i  0 ; ++i )
b[c[a[i]/(n*n)]++] = a[i];

// sorted result is in b[].

Dave

On Aug 15, 4:48 pm, Ankur Garg ankurga...@gmail.com wrote:
 @Dave

 Dude can u provide a sample code...What do u mean by radix n ..also radix
 sort requires some other sorting algo to sort digits

 Regards
 Ankur



 On Sun, Aug 14, 2011 at 1:33 PM, Dave dave_and_da...@juno.com wrote:
  @Ankur: Use a radix sort with radix n. It will take 3 passes to sort
  the 3 base-n digits, each of O(n), so the overall order will be O(n).

  On Aug 14, 10:08 am, Ankur Garg ankurga...@gmail.com wrote:
   This is one question from Coreman

   3rd Edition -

   8-3-4 --  Sort n integers in the range 0 to n^3 -1 in O(n) time

   Any ideas how to do this in O(n)

  --
  You received this message because you are subscribed to the Google Groups
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] akamai first round???

2011-08-16 Thread htross
hai can anybody tell me what kind of questions will be asked in akamai
technologies???please help

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: akamai.....

2011-08-16 Thread htross
what questions were asked in first round???

On Aug 15, 8:05 pm, Shravanthi U M shravanthium...@gmail.com wrote:
 On Mon, Aug 15, 2011 at 8:04 AM, Shravanthi U M
 shravanthium...@gmail.comwrote:







  In Bangalore Institute of Technology, bangalore

  regards,
  Shravanthi U M
 http://shravanthimohan.wordpress.com

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] sumitabha das unix ebook ?

2011-08-16 Thread MAC
thanks Deoki for this also :)

On Tue, Aug 16, 2011 at 10:29 AM, Deoki Nandan deok...@gmail.com wrote:

 but this is not whole book only some portion


 On Tue, Aug 16, 2011 at 10:28 AM, Deoki Nandan deok...@gmail.com wrote:

 here is the link for sumitbha das ebook

 http://www.mediafire.com/?ej74twjczauidil

 On Tue, Aug 16, 2011 at 9:57 AM, MAC macatad...@gmail.com wrote:

 does anyone has sumitabha das unix ebook for unix ?

 --
 thanks
 --mac

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 **With Regards
 Deoki Nandan Vishwakarma

 *
 *




 --
 **With Regards
 Deoki Nandan Vishwakarma

 *
 *

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
thanks
--mac

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] array question

2011-08-16 Thread MAC
Given an array of integers. Each number in the array repeats ODD number of
times, but only 1 number repeated for EVEN number of times. Find that
number.


-- 
thanks
--mac

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] regarding amdocs interview questions

2011-08-16 Thread abhishek
@ prateek

r u appearing offcampus??? from which college u r?
just brush up ur c concepts like array,dynamic memory allocation and
pointers. and sql is very important like view,index .. and little bit
imp commands of unix

On 8/15/11, prateek gupta prateek21590gu...@gmail.com wrote:
 hey guys,
 Tell me about amdocs interview questions and also post the good links
 for preparation as my interview is scheduled on friday.
 thanks in advance.
 Regards
 Prateek Gupta

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.



-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] array question

2011-08-16 Thread Raghavan
One easier thing would be to use a map to solve this.



On Tue, Aug 16, 2011 at 1:41 PM, MAC macatad...@gmail.com wrote:


 Given an array of integers. Each number in the array repeats ODD number of
 times, but only 1 number repeated for EVEN number of times. Find that
 number.


 --
 thanks
 --mac

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
Thanks and Regards,
Raghavan KL

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] reg : Hashing

2011-08-16 Thread Mahesh Goud
Can some one point out some top class problems (blogs, tutorials)
related to hashing ?

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: EMC Software

2011-08-16 Thread siva viknesh
hi .. Any idea about first round in EMC ? Do they concentrate on
general aptitude also or just fully c, cpp ??.. If anyone recently
attended plz share

On Aug 15, 11:23 pm, dexter does dxterd...@gmail.com wrote:
 can anyone post EMC software sample questions and its pattern ASAP??

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] array question

2011-08-16 Thread Raghavan
@sukran:
If you were asking for the map based solution

space and time complexity would be o(n).


On Tue, Aug 16, 2011 at 2:34 PM, sukran dhawan sukrandha...@gmail.comwrote:

 what is the complexity in which it has been done ?

 On Tue, Aug 16, 2011 at 1:41 PM, MAC macatad...@gmail.com wrote:


 Given an array of integers. Each number in the array repeats ODD number of
 times, but only 1 number repeated for EVEN number of times. Find that
 number.


 --
 thanks
 --mac

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
Thanks and Regards,
Raghavan KL

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Win Shuttle

2011-08-16 Thread Neha Gupta
@simran thnx for the info.
@sanjay.i vl definitely ask about CTC and inhand salary. I am in IGIT
(Indira Gandhi Institute Of Technology, Kashmere Gate)

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Any one having ebook of Discrete Mathematics and Its Applications, Kenneth Rosen

2011-08-16 Thread Rahul Singhal
Herllo all,
Plz mail the ebook of  Discrete Mathematics and Its Applications, Kenneth
Rosen, if possioble.

Thanks

-- 
Rahul singhal

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: find numbers whose difference is min

2011-08-16 Thread Shuaib
Yes it will work in this specific case. What I meant was that Radix sort isn't 
always applicable in general to achieve linear time sorting. Its complexity 
isn't exactly O(N) rather O(d*N) where d is the number of bytes each of our 
item consumes. So if the elements in array aren't from a finite range, that 
would be an issue. 

Correct me if I am wrong. 

--
Shuaib
http://twitter.com/ShuaibKhan
http://www.bytehood.com/

On 16-Aug-2011, at 11:05 AM, Dave dave_and_da...@juno.com wrote:

 @Shuaib: It will work in all cases. If you don't think so, give a
 counterexample.
 
 Dave
 
 On Aug 16, 12:50 am, Shuaib aries.shu...@gmail.com wrote:
 That will work but not in all cases as radix sort isn't a generalized 
 sorting algorithm, is it? :)
 
 --
 Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/
 
 On 16-Aug-2011, at 10:10 AM, Dave dave_and_da...@juno.com wrote:
 
 
 
 @Shuaib: You could sort the numbers in O(n) with a radix sort, and
 then finding the min is easy. Mind you, the radix sort might be slower
 than an O(n log n) sort, but still it satisfies the O(n) constraint.
 
 Dave
 
 On Aug 15, 8:41 pm, Shuaib aries.shu...@gmail.com wrote:
 That won't work. And I don't think an O(n) solution is possible.
 
 --
 Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/
 
 On 16-Aug-2011, at 6:25 AM, sukran dhawan sukrandha...@gmail.com wrote:
 
 find the minimum of two numbers in a loop o(n) and subtract the two
 
 On Tue, Aug 16, 2011 at 6:13 AM, Brijesh Upadhyay 
 brijeshupadhyay...@gmail.com wrote:
 Algorithm to find the two numbers whose difference is minimum among the 
 set of numbers. For example the sequence is 5, 13, 7, 0, 10, 20, 1, 15, 
 4, 19 The algorithm should return min diff = 20-19 = 1. Constraint - Time 
 Complexity O(N)
 
 --
 You received this message because you are subscribed to the Google Groups 
 Algorithm Geeks group.
 To view this discussion on the web 
 visithttps://groups.google.com/d/msg/algogeeks/-/U8gTWUISJn8J.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to 
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group 
 athttp://groups.google.com/group/algogeeks?hl=en.
 
 --
 You received this message because you are subscribed to the Google Groups 
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to 
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group 
 athttp://groups.google.com/group/algogeeks?hl=en.
 
 --
 You received this message because you are subscribed to the Google Groups 
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to 
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group 
 athttp://groups.google.com/group/algogeeks?hl=en.
 
 -- 
 You received this message because you are subscribed to the Google Groups 
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to 
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at 
 http://groups.google.com/group/algogeeks?hl=en.
 

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] array question

2011-08-16 Thread MAC
The question needed o(1) space and o(n)  time ...  o(n) map approach is
obviously fine but space is taken up ...

On Tue, Aug 16, 2011 at 2:38 PM, Raghavan its...@gmail.com wrote:

 @sukran:
 If you were asking for the map based solution

 space and time complexity would be o(n).


 On Tue, Aug 16, 2011 at 2:34 PM, sukran dhawan sukrandha...@gmail.comwrote:

 what is the complexity in which it has been done ?

 On Tue, Aug 16, 2011 at 1:41 PM, MAC macatad...@gmail.com wrote:


 Given an array of integers. Each number in the array repeats ODD number
 of times, but only 1 number repeated for EVEN number of times. Find that
 number.


 --
 thanks
 --mac

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Thanks and Regards,
 Raghavan KL

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
thanks
--mac

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] amazon question

2011-08-16 Thread Suganya Palaniappan
@rajeev : Can u pls explain the second approach...??

On Mon, Aug 15, 2011 at 10:09 PM, sandeep pandey 
sandeep.masum4...@gmail.com wrote:

 dyamic programming.

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
--Regards,
Sug@ny@...

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Any one having ebook of Discrete Mathematics and Its Applications, Kenneth Rosen

2011-08-16 Thread kumar raja
Go for 4shared.com there u will find all kind of books

On 16 August 2011 02:23, Rahul Singhal nitk.ra...@gmail.com wrote:

 Herllo all,
 Plz mail the ebook of  Discrete Mathematics and Its Applications, Kenneth
 Rosen, if possioble.

 Thanks

 --
 Rahul singhal


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
Regards
Kumar Raja
M.Tech(SIT)
IIT Kharagpur,
10it60...@iitkgp.ac.in
7797137043.
09491690115.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] array question

2011-08-16 Thread Raghavan
   - Sort the array - o(log n) based on the sorting strategy might be radix
   sort
   - check the numbers count have a counter o(1) space and again o(n) time
   - changing from one number to other check counter%2 == 0 if so then we
   get answer

So consolidated time would be o(n) and space is o(1);

On Tue, Aug 16, 2011 at 3:20 PM, MAC macatad...@gmail.com wrote:

 The question needed o(1) space and o(n)  time ...  o(n) map approach is
 obviously fine but space is taken up ...


 On Tue, Aug 16, 2011 at 2:38 PM, Raghavan its...@gmail.com wrote:

 @sukran:
 If you were asking for the map based solution

 space and time complexity would be o(n).


 On Tue, Aug 16, 2011 at 2:34 PM, sukran dhawan sukrandha...@gmail.comwrote:

 what is the complexity in which it has been done ?

 On Tue, Aug 16, 2011 at 1:41 PM, MAC macatad...@gmail.com wrote:


 Given an array of integers. Each number in the array repeats ODD number
 of times, but only 1 number repeated for EVEN number of times. Find that
 number.


 --
 thanks
 --mac

  --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Thanks and Regards,
 Raghavan KL

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 thanks
 --mac

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
Thanks and Regards,
Raghavan KL

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: c output

2011-08-16 Thread roopesh bajaj
it is compiler dependent

On Aug 1, 5:20 pm, thanu moorthy moorthyth...@gmail.com wrote:
 Please help me...

 How can the following output be obtained :

  1.main()

 {

  int i=1;

 printf(%d\t%d\t%d\t,i,i++,i);

 }

 output: 2 1 2

  2.main()

 {

  int i=1;

 printf(%d\t%d\t%d\t,i,++i,i);

 }

 output: 2 2 2

  3.main()

 {

  int i=1;

 printf(%d\t%d\t%d\t,i,i++,i++);

 }

 output: 3 2 1

  4.main()

 {

  int i=1;

 printf(%d\t%d\t%d\t,i,++i,++i);

 }

 output: 3 3 3

 Regards
 by THANU

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks]

2011-08-16 Thread ravinder s
a brick is 4kg.If you make the brick 1/4 then how much will be its weight.?

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: regarding amdocs interview questions

2011-08-16 Thread prateek gupta
@abhishek
yes i am appearing through offcampus drive.plz tell me regarding sql
and unix preparation as i belong to ECE and don't have good knowledge
of these subjects.

On Aug 16, 1:29 pm, abhishek abhishekgupta0...@gmail.com wrote:
 @ prateek

 r u appearing offcampus??? from which college u r?
 just brush up ur c concepts like array,dynamic memory allocation and
 pointers. and sql is very important like view,index .. and little bit
 imp commands of unix

 On 8/15/11, prateek gupta prateek21590gu...@gmail.com wrote:







  hey guys,
  Tell me aboutamdocsinterview questions and also post the good links
  for preparation as my interview is scheduled on friday.
  thanks in advance.
  Regards
  Prateek Gupta

  --
  You received this message because you are subscribed to the Google Groups
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Fwd: [algogeeks]

2011-08-16 Thread sukran dhawan
-- Forwarded message --
From: ravinder s ravinderr...@gmail.com
Date: Tue, Aug 16, 2011 at 4:15 PM
Subject: [algogeeks]
To: algogeeks@googlegroups.com


a brick is 4kg.If you make the brick 1/4 then how much will be its weight.?

-- 
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/algogeeks?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Fwd: [algogeeks]

2011-08-16 Thread sukran dhawan
which college are u from?
-- Forwarded message --
From: ravinder s ravinderr...@gmail.com
Date: Tue, Aug 16, 2011 at 4:15 PM
Subject: [algogeeks]
To: algogeeks@googlegroups.com


a brick is 4kg.If you make the brick 1/4 then how much will be its weight.?

-- 
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/algogeeks?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] array question

2011-08-16 Thread wujin chen
i think XOR operator should be used to solve question.
Given the integers in the array A: n1,n2...nk,
we can do this recursively:
XOR all the integers in A, assume the result is F = n1^n2^...^nk,
F must not be 0.
for i-th bit in F from rightmost to left most:
 if the i-th bit is 1, halve A into 2 parts: A1 and A2, that elements in
A1 hold 1 in the i-th bit and A2 hold 0 in the i-th bit
 if XOR(A1) == 0
 A1 is the result
if  XOR(A2) == 0
 A2 is the result
 if the result has not been got, we will use the next non-zero bit in F
to halve A1 and A2

excepte the first pass,we can do some optimization so that there is no need
to compute the F with XOR one by one. we can compute F when halve the array.
but in this way , the time complexity may be not linear
if the question is like this:

 Given an array of integers. Each number in the array repeats 3 number of
 times, but only 1 number repeated for 2 number of times. Find that number.

it can be solved in O(n), because we can use the number to eliminate some
parts.









2011/8/16 Raghavan its...@gmail.com


- Sort the array - o(log n) based on the sorting strategy might be
radix sort
- check the numbers count have a counter o(1) space and again o(n) time
- changing from one number to other check counter%2 == 0 if so then we
get answer

 So consolidated time would be o(n) and space is o(1);

 On Tue, Aug 16, 2011 at 3:20 PM, MAC macatad...@gmail.com wrote:

 The question needed o(1) space and o(n)  time ...  o(n) map approach is
 obviously fine but space is taken up ...


 On Tue, Aug 16, 2011 at 2:38 PM, Raghavan its...@gmail.com wrote:

 @sukran:
 If you were asking for the map based solution

 space and time complexity would be o(n).


 On Tue, Aug 16, 2011 at 2:34 PM, sukran dhawan 
 sukrandha...@gmail.comwrote:

 what is the complexity in which it has been done ?

 On Tue, Aug 16, 2011 at 1:41 PM, MAC macatad...@gmail.com wrote:


 Given an array of integers. Each number in the array repeats ODD number
 of times, but only 1 number repeated for EVEN number of times. Find that
 number.


 --
 thanks
 --mac

  --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Thanks and Regards,
 Raghavan KL

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 thanks
 --mac

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Thanks and Regards,
 Raghavan KL

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks]

2011-08-16 Thread Carl Barton
Depends which quarter you're measuring. Bricks aren't a uniform cuboid so
wont be 1kg per quarter

On 16 August 2011 12:16, sukran dhawan sukrandha...@gmail.com wrote:


 which college are u from?
 -- Forwarded message --
 From: ravinder s ravinderr...@gmail.com
 Date: Tue, Aug 16, 2011 at 4:15 PM
 Subject: [algogeeks]
 To: algogeeks@googlegroups.com


 a brick is 4kg.If you make the brick 1/4 then how much will be its weight.?


 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Algorithms For Interviews

2011-08-16 Thread kamesh Singh
Hi All,

Please send me the link or pdf of Book Algorithms For Interviews By adnan
aziz, if anybody have.

Thanks

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks]

2011-08-16 Thread sukran dhawan
can anybody send the ebook of test ur c++ skills by yashwanth kanetkar if u
ve ?

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] novell

2011-08-16 Thread altu faltu
can anyone give the paper of novell if it has visited any campus dis
year??

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] DELOITTE

2011-08-16 Thread karthik fbk
Have Deloitte visited any of your colleges ?
If so can you plz share your interview experience ?
What questions were asked in written ? Were the quants questions so
difficult or as same as R S Agarwal type questions ?

If you have any additional information , plz share it ..

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] DELOITTE

2011-08-16 Thread somya mishra
ya first round was rs agarwal type question. for gd round do go thoroughly
thru ur software engineer concepts interview round was pretty easy jst some
general quest nothing much technical

On Tue, Aug 16, 2011 at 6:23 PM, karthik fbk fbk@gmail.com wrote:

 Have Deloitte visited any of your colleges ?
 If so can you plz share your interview experience ?
 What questions were asked in written ? Were the quants questions so
 difficult or as same as R S Agarwal type questions ?

 If you have any additional information , plz share it ..

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.



-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] DELOITTE

2011-08-16 Thread karthik fbk
What about verbal sections ? How tough were verbal questions ?
What type of questions were asked in verbal section ?

On Tue, Aug 16, 2011 at 6:34 PM, somya mishra somya.bvm...@gmail.comwrote:

 ya first round was rs agarwal type question. for gd round do go thoroughly
 thru ur software engineer concepts interview round was pretty easy jst some
 general quest nothing much technical


 On Tue, Aug 16, 2011 at 6:23 PM, karthik fbk fbk@gmail.com wrote:

 Have Deloitte visited any of your colleges ?
 If so can you plz share your interview experience ?
 What questions were asked in written ? Were the quants questions so
 difficult or as same as R S Agarwal type questions ?

 If you have any additional information , plz share it ..

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] GSOC

2011-08-16 Thread saurabh chhabra
can anyone help me in preparing for GSOC(Summer of Code),2012?
Please give me a description of what exactly it is and what all we
need to know to get selected in it.
kindly throw some light.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] DBMS question

2011-08-16 Thread tech rascal
use of views in the database??

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: find numbers whose difference is min

2011-08-16 Thread Dave
@Shuaib: We are talking about an array of numbers, arent't we? It is
natural to assume that the numbers fall into one of the defined data
types.

Dave

On Aug 16, 4:23 am, Shuaib aries.shu...@gmail.com wrote:
 Yes it will work in this specific case. What I meant was that Radix sort 
 isn't always applicable in general to achieve linear time sorting. Its 
 complexity isn't exactly O(N) rather O(d*N) where d is the number of bytes 
 each of our item consumes. So if the elements in array aren't from a finite 
 range, that would be an issue.

 Correct me if I am wrong.

 --
 Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/

 On 16-Aug-2011, at 11:05 AM, Dave dave_and_da...@juno.com wrote:



  @Shuaib: It will work in all cases. If you don't think so, give a
  counterexample.

  Dave

  On Aug 16, 12:50 am, Shuaib aries.shu...@gmail.com wrote:
  That will work but not in all cases as radix sort isn't a generalized 
  sorting algorithm, is it? :)

  --
  Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/

  On 16-Aug-2011, at 10:10 AM, Dave dave_and_da...@juno.com wrote:

  @Shuaib: You could sort the numbers in O(n) with a radix sort, and
  then finding the min is easy. Mind you, the radix sort might be slower
  than an O(n log n) sort, but still it satisfies the O(n) constraint.

  Dave

  On Aug 15, 8:41 pm, Shuaib aries.shu...@gmail.com wrote:
  That won't work. And I don't think an O(n) solution is possible.

  --
  Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/

  On 16-Aug-2011, at 6:25 AM, sukran dhawan sukrandha...@gmail.com wrote:

  find the minimum of two numbers in a loop o(n) and subtract the two

  On Tue, Aug 16, 2011 at 6:13 AM, Brijesh Upadhyay 
  brijeshupadhyay...@gmail.com wrote:
  Algorithm to find the two numbers whose difference is minimum among the 
  set of numbers. For example the sequence is 5, 13, 7, 0, 10, 20, 1, 15, 
  4, 19 The algorithm should return min diff = 20-19 = 1. Constraint - 
  Time Complexity O(N)

  --
  You received this message because you are subscribed to the Google 
  Groups Algorithm Geeks group.
  To view this discussion on the web 
  visithttps://groups.google.com/d/msg/algogeeks/-/U8gTWUISJn8J.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to 
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group 
  athttp://groups.google.com/group/algogeeks?hl=en.

  --
  You received this message because you are subscribed to the Google 
  Groups Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to 
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group 
  athttp://groups.google.com/group/algogeeks?hl=en.

  --
  You received this message because you are subscribed to the Google Groups 
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to 
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group 
  athttp://groups.google.com/group/algogeeks?hl=en.

  --
  You received this message because you are subscribed to the Google Groups 
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to 
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group 
  athttp://groups.google.com/group/algogeeks?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: array question

2011-08-16 Thread Dave
@Raghavan: But aren't maps implemented as binary search trees? That
would make insertion and searching O(log n), and the overall operation
O(n log n).

Dave

On Aug 16, 4:08 am, Raghavan its...@gmail.com wrote:
 @sukran:
 If you were asking for the map based solution

 space and time complexity would be o(n).

 On Tue, Aug 16, 2011 at 2:34 PM, sukran dhawan sukrandha...@gmail.comwrote:





  what is the complexity in which it has been done ?

  On Tue, Aug 16, 2011 at 1:41 PM, MAC macatad...@gmail.com wrote:

  Given an array of integers. Each number in the array repeats ODD number of
  times, but only 1 number repeated for EVEN number of times. Find that
  number.

  --
  thanks
  --mac

   --
  You received this message because you are subscribed to the Google Groups
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

   --
  You received this message because you are subscribed to the Google Groups
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

 --
 Thanks and Regards,
 Raghavan KL

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] DBMS question

2011-08-16 Thread venkateswari srinivasan
with out changing table , we can provide the required information to the
user...

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] DELOITTE

2011-08-16 Thread somya mishra
decent level nt very tough bt also nt very easy also

On Tue, Aug 16, 2011 at 6:37 PM, karthik fbk fbk@gmail.com wrote:

 What about verbal sections ? How tough were verbal questions ?
 What type of questions were asked in verbal section ?

 On Tue, Aug 16, 2011 at 6:34 PM, somya mishra somya.bvm...@gmail.comwrote:

 ya first round was rs agarwal type question. for gd round do go thoroughly
 thru ur software engineer concepts interview round was pretty easy jst some
 general quest nothing much technical


 On Tue, Aug 16, 2011 at 6:23 PM, karthik fbk fbk@gmail.com wrote:

 Have Deloitte visited any of your colleges ?
 If so can you plz share your interview experience ?
 What questions were asked in written ? Were the quants questions so
 difficult or as same as R S Agarwal type questions ?

 If you have any additional information , plz share it ..

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] DELOITTE

2011-08-16 Thread karthik fbk
thnk you .

On Tue, Aug 16, 2011 at 7:27 PM, somya mishra somya.bvm...@gmail.comwrote:

 decent level nt very tough bt also nt very easy also

 On Tue, Aug 16, 2011 at 6:37 PM, karthik fbk fbk@gmail.com wrote:

 What about verbal sections ? How tough were verbal questions ?
 What type of questions were asked in verbal section ?

 On Tue, Aug 16, 2011 at 6:34 PM, somya mishra somya.bvm...@gmail.comwrote:

 ya first round was rs agarwal type question. for gd round do go
 thoroughly thru ur software engineer concepts interview round was pretty
 easy jst some general quest nothing much technical


 On Tue, Aug 16, 2011 at 6:23 PM, karthik fbk fbk@gmail.com wrote:

 Have Deloitte visited any of your colleges ?
 If so can you plz share your interview experience ?
 What questions were asked in written ? Were the quants questions so
 difficult or as same as R S Agarwal type questions ?

 If you have any additional information , plz share it ..

 --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: akamai first round???

2011-08-16 Thread Akhilesh Kumar K C


Akamai this year had a three types(written round)
1) aptitude(20 questions ) 25 minutes..Ratio 1 was lengthy...
2)techincal(25 minutes) 20 questions..
3) subjective:(4 questions)
a)E R diagram construction(prof,teacher,student ,projects some
problem)
b) a program to establish a no such that all it divisors sum is equal
to the no ..in other words, find a no such that n=a+b+c+d; where
1a,b,c,dn;;
c) i forgot...
d) question with trees..

In the interview much of the question were asked on the database(ER
diagram) and normal c,c++,data structures..

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] MICROSOFT RESEARCH INTERN

2011-08-16 Thread arvind kumar
Hi friends
Can anyone please tell me about microsoft research intern-the
selection process??
Is it the same or is it different from microsoft itc??

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Memory Leak

2011-08-16 Thread Prem Krishna Chettri
Use valgrind..

On Mon, Aug 15, 2011 at 10:39 AM, Ankur Khurana ankur.kkhur...@gmail.comwrote:

 @rajeev  +1 . great software .


 On Mon, Aug 15, 2011 at 9:33 AM, rajeev bharshetty 
 rajeevr...@gmail.comwrote:

 Valgrind is an effective open source tool to detect memory leaks and many
 more bugs in the program.

 http://valgrind.org/


 On Mon, Aug 15, 2011 at 6:31 AM, *$* gopi.komand...@gmail.com wrote:

 use crtdbg.h

 _crtdumpmemoryleaks() .. will work only in debug version.


 On Mon, Aug 15, 2011 at 4:01 AM, Ankur Garg ankurga...@gmail.comwrote:

 Where ever u have allocated dynamic memory that qualifies to be a
 culprit for causing memory leak ...Scan through the code if the memory 
 block
 has been deallocated or not ...


 Regards
 Ankur


 On Sun, Aug 14, 2011 at 6:03 PM, SAMMM somnath.nit...@gmail.comwrote:

 How to detect in which line the Memory Leak has occured ?? I want the
 line number where the Memory leak occurs ??? Give every wild answer u
 can think off 

 --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Thx,
 --Gopi

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Regards
 Rajeev N B http://www.opensourcemania.co.cc

 *Winners Don't do Different things , they do things Differently*

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Ankur Khurana
 Computer Science
 Netaji Subhas Institute Of Technology
 Delhi.

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] DELOITTE

2011-08-16 Thread somya mishra
no probs mate all the best

On Tue, Aug 16, 2011 at 10:01 AM, karthik fbk fbk@gmail.com wrote:

 thnk you .

 On Tue, Aug 16, 2011 at 7:27 PM, somya mishra somya.bvm...@gmail.comwrote:

 decent level nt very tough bt also nt very easy also

 On Tue, Aug 16, 2011 at 6:37 PM, karthik fbk fbk@gmail.com wrote:

 What about verbal sections ? How tough were verbal questions ?
 What type of questions were asked in verbal section ?

 On Tue, Aug 16, 2011 at 6:34 PM, somya mishra somya.bvm...@gmail.comwrote:

 ya first round was rs agarwal type question. for gd round do go
 thoroughly thru ur software engineer concepts interview round was pretty
 easy jst some general quest nothing much technical


 On Tue, Aug 16, 2011 at 6:23 PM, karthik fbk fbk@gmail.com wrote:

 Have Deloitte visited any of your colleges ?
 If so can you plz share your interview experience ?
 What questions were asked in written ? Were the quants questions so
 difficult or as same as R S Agarwal type questions ?

 If you have any additional information , plz share it ..

 --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: DELOITTE

2011-08-16 Thread siva viknesh
hi can u plz tell me in which areas of aps did they concentrate .. i
mean the topics...work and time, probability ..like thatthere were
c / cpp aps ???

On Aug 16, 7:11 pm, somya mishra somya.bvm...@gmail.com wrote:
 no probs mate all the best







 On Tue, Aug 16, 2011 at 10:01 AM, karthik fbk fbk@gmail.com wrote:
  thnk you .

  On Tue, Aug 16, 2011 at 7:27 PM, somya mishra somya.bvm...@gmail.comwrote:

  decent level nt very tough bt also nt very easy also

  On Tue, Aug 16, 2011 at 6:37 PM, karthik fbk fbk@gmail.com wrote:

  What about verbal sections ? How tough were verbal questions ?
  What type of questions were asked in verbal section ?

  On Tue, Aug 16, 2011 at 6:34 PM, somya mishra 
  somya.bvm...@gmail.comwrote:

  ya first round was rs agarwal type question. for gd round do go
  thoroughly thru ur software engineer concepts interview round was pretty
  easy jst some general quest nothing much technical

  On Tue, Aug 16, 2011 at 6:23 PM, karthik fbk fbk@gmail.com wrote:

  Have Deloitte visited any of your colleges ?
  If so can you plz share your interview experience ?
  What questions were asked in written ? Were the quants questions so
  difficult or as same as R S Agarwal type questions ?

  If you have any additional information , plz share it ..

  --
  You received this message because you are subscribed to the Google
  Groups Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

   --
  You received this message because you are subscribed to the Google
  Groups Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

   --
  You received this message because you are subscribed to the Google Groups
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

   --
  You received this message because you are subscribed to the Google Groups
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

   --
  You received this message because you are subscribed to the Google Groups
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: find numbers whose difference is min

2011-08-16 Thread Shuaib Khan
Dave, I agree. :)

On Tue, Aug 16, 2011 at 6:33 PM, Dave dave_and_da...@juno.com wrote:

 @Shuaib: We are talking about an array of numbers, arent't we? It is
 natural to assume that the numbers fall into one of the defined data
 types.

 Dave

 On Aug 16, 4:23 am, Shuaib aries.shu...@gmail.com wrote:
  Yes it will work in this specific case. What I meant was that Radix sort
 isn't always applicable in general to achieve linear time sorting. Its
 complexity isn't exactly O(N) rather O(d*N) where d is the number of bytes
 each of our item consumes. So if the elements in array aren't from a finite
 range, that would be an issue.
 
  Correct me if I am wrong.
 
  --
  Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/
 
  On 16-Aug-2011, at 11:05 AM, Dave dave_and_da...@juno.com wrote:
 
 
 
   @Shuaib: It will work in all cases. If you don't think so, give a
   counterexample.
 
   Dave
 
   On Aug 16, 12:50 am, Shuaib aries.shu...@gmail.com wrote:
   That will work but not in all cases as radix sort isn't a generalized
 sorting algorithm, is it? :)
 
   --
   Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/
 
   On 16-Aug-2011, at 10:10 AM, Dave dave_and_da...@juno.com wrote:
 
   @Shuaib: You could sort the numbers in O(n) with a radix sort, and
   then finding the min is easy. Mind you, the radix sort might be
 slower
   than an O(n log n) sort, but still it satisfies the O(n) constraint.
 
   Dave
 
   On Aug 15, 8:41 pm, Shuaib aries.shu...@gmail.com wrote:
   That won't work. And I don't think an O(n) solution is possible.
 
   --
   Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/
 
   On 16-Aug-2011, at 6:25 AM, sukran dhawan sukrandha...@gmail.com
 wrote:
 
   find the minimum of two numbers in a loop o(n) and subtract the two
 
   On Tue, Aug 16, 2011 at 6:13 AM, Brijesh Upadhyay 
 brijeshupadhyay...@gmail.com wrote:
   Algorithm to find the two numbers whose difference is minimum among
 the set of numbers. For example the sequence is 5, 13, 7, 0, 10, 20, 1, 15,
 4, 19 The algorithm should return min diff = 20-19 = 1. Constraint - Time
 Complexity O(N)
 
   --
   You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
   To view this discussion on the web visithttps://
 groups.google.com/d/msg/algogeeks/-/U8gTWUISJn8J.
   To post to this group, send email to algogeeks@googlegroups.com.
   To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
   For more options, visit this group athttp://
 groups.google.com/group/algogeeks?hl=en.
 
   --
   You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
   To post to this group, send email to algogeeks@googlegroups.com.
   To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
   For more options, visit this group athttp://
 groups.google.com/group/algogeeks?hl=en.
 
   --
   You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
   To post to this group, send email to algogeeks@googlegroups.com.
   To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
   For more options, visit this group athttp://
 groups.google.com/group/algogeeks?hl=en.
 
   --
   You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
   To post to this group, send email to algogeeks@googlegroups.com.
   To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
   For more options, visit this group athttp://
 groups.google.com/group/algogeeks?hl=en.

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
Shuaib
http://www.bytehood.com
http://twitter.com/ShuaibKhan

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] GSOC

2011-08-16 Thread dilip makwana
Ya please some one share info regarding this .

@saurabh thanks for askin this 

On 16 August 2011 19:00, saurabh chhabra saurabh131...@gmail.com wrote:

 can anyone help me in preparing for GSOC(Summer of Code),2012?
 Please give me a description of what exactly it is and what all we
 need to know to get selected in it.
 kindly throw some light.

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
*Dilip Makwana*
VJTI
BTech Computers Engineering
2009-2013

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: Algorithms For Interviews

2011-08-16 Thread Yasir
It was posted recently..
Check the achieves. :)

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/algogeeks/-/Lv9GSMFFS00J.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: Algorithms For Interviews

2011-08-16 Thread Yasir
Typo: achieves -- archives  

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/algogeeks/-/ccCkVtfs3y4J.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Algorithms For Interviews

2011-08-16 Thread Nitin Nizhawan
http://www.fileflyer.com/view/XyBZGA8

On Tue, Aug 16, 2011 at 8:07 PM, Yasir yasir@gmail.com wrote:

 Typo: achieves -- archives

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To view this discussion on the web visit
 https://groups.google.com/d/msg/algogeeks/-/ccCkVtfs3y4J.

 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Algorithms For Interviews

2011-08-16 Thread ravi kumar
heyy nitin.. it says da file izz locked .. can u mail me da buk.. thanx in
advance

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Komli Media

2011-08-16 Thread Navneet Gupta
Any feedback on Komli Media? How's their compensation like for college
freshers? Any interview questions you would like to share?

-- 
Regards,
Navneet

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Algorithms For Interviews

2011-08-16 Thread Nitin Nizhawan
sent to you ravi

On Tue, Aug 16, 2011 at 8:16 PM, ravi kumar ravikumar...@gmail.com wrote:


 heyy nitin.. it says da file izz locked .. can u mail me da buk.. thanx in
 advance

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] J.P.MORGAN

2011-08-16 Thread tejaswini
Hi guys
Have J.P.Morgan visited any of ur colleges???
If so plz share about da interview process.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/algogeeks/-/ge2HIVc8YL0J.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: Memory Leak

2011-08-16 Thread SAMMM
If u were asked this question in an interview , wht would be your
answer ?

Using Valgrind .  If the interviewer ask without using other
software , then wht ???

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Algorithms For Interviews

2011-08-16 Thread ravi kumar
Jus downloaded nitin... thankyou verymuch.. gudd jobb..

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Number theory

2011-08-16 Thread sameer gupta
 no. of ways you can write a no. as sum of other non-zero positive
integers
like 3 can be written in
3 ways:
1+1+1,
1+2
2+1
 imp. 2+1 and 1+2 are different
find the answer and give and prove formula for any value 'n'

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Algorithms For Interviews

2011-08-16 Thread Yogesh Yadav
plz upload it againi cant open it...

On Tue, Aug 16, 2011 at 8:31 PM, Nitin Nizhawan nitin.nizha...@gmail.comwrote:

 sent to you ravi

 On Tue, Aug 16, 2011 at 8:16 PM, ravi kumar ravikumar...@gmail.comwrote:


 heyy nitin.. it says da file izz locked .. can u mail me da buk.. thanx in
 advance

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Memory Leak

2011-08-16 Thread Suraj Fale
Crash dump file is one of the solution... create a mini-dump file.. and then
analyze it by various software like DebugView etc..

On Tue, Aug 16, 2011 at 8:35 PM, SAMMM somnath.nit...@gmail.com wrote:

 If u were asked this question in an interview , wht would be your
 answer ?

 Using Valgrind .  If the interviewer ask without using other
 software , then wht ???

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
Regards
Suraj Fale
+91-9766103115

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] J.P.MORGAN

2011-08-16 Thread anitha sekaran
The written test of it wld be vry easy.. And yo wld hve a tech round,
followed by a grp activity and another onr hr tech round... In the first
round they generally ask yo abt ur projects... Final tech round is based on
ur funda on c , c++ ,java. :) :)

On Tue, Aug 16, 2011 at 8:33 PM, tejaswini
amruthakavitejasw...@gmail.comwrote:

 Hi guys
 Have J.P.Morgan visited any of ur colleges???
 If so plz share about da interview process.

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To view this discussion on the web visit
 https://groups.google.com/d/msg/algogeeks/-/ge2HIVc8YL0J.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] C output

2011-08-16 Thread rohit


#includestdio.hconst char *fun();
int main()
{
char *ptr = fun();
return 0;
}const char *fun()
{
return Hello;
}


Why doesn't this code give error??

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/algogeeks/-/qeUTNwGNKfwJ.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] MICROSOFT RESEARCH INTERN

2011-08-16 Thread pacific :-)
Its different.

There are separate kind of interviews for both looking for different things.

On Tue, Aug 16, 2011 at 5:18 PM, arvind kumar arvindk...@gmail.com wrote:

 Hi friends
 Can anyone please tell me about microsoft research intern-the
 selection process??
 Is it the same or is it different from microsoft itc??

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
regards,
chinna.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Number theory

2011-08-16 Thread Nitin Nizhawan
I think 2^(n-1) - 1

On Tue, Aug 16, 2011 at 8:36 PM, sameer gupta gupta.sameer...@gmail.comwrote:

  no. of ways you can write a no. as sum of other non-zero positive
 integers
 like 3 can be written in
 3 ways:
 1+1+1,
 1+2
 2+1
  imp. 2+1 and 1+2 are different
 find the answer and give and prove formula for any value 'n'

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.



-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: Number theory

2011-08-16 Thread Brijesh Upadhyay
Actually it was one of the assignments given to me in lab.. here is the code

#include iostream.h

#include conio.h

using namespace std;

int a[20][20][20]; // Global declration to make every cell's default value 
to zero

// 3D matrix to implement the algorithm

void combinations(int number) // function that accepts the number whose 
combination , you

{

int i, j, k, larg, m, n, flag;

for(i=1; i=number; i++)

a[i][0][0]=i;

i=1;

while(i=number)

{

// first row of each number is copied by that number

// external loop to access no. whose combination are inserted

flag=1;

j=1;

do{

//position of rows that is being modified

// inner loop that will run through i

for(k=0; a[j][k][0]!=0; k++) // innermost loop that will check for 
largest/last no.

{

for(larg=0; a[j][k][larg]!=0; larg++); //to check last value

larg--;

if(i-ja[j][k][larg])

{

for(m=0; m=larg; m++)

a[i][flag][m] = a[j][k][m];

a[i][flag][m] = i-j;

flag++;

}

// comapring last value with difference

// copy all existing values to current number

// insert difference between numbers

//increase the pointer to insert next combination

}

j++;

}while(j=i);

i++;

}

k=number;

for(i=0; a[k][i][0]!=0; i++) {

couta[k][i][0];

for(j=1; a[k][i][j]!=0; j++)

cout+a[k][i][j];

// printing of all combination of number

cout\n;

}

}

int main()

{

int number;

coutEnter the natural number: ;

cinnumber;

combinations(number);

getch();

return 0;

}

//input the number whose combination you want

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/algogeeks/-/CsTCslXuC88J.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] C output

2011-08-16 Thread Sanjay Rajpal
This is becuase Hello is a constant string and constant strings get stored
in *Data Area, not in stack for the function you called. *Thats why pointer
to constant string will be returned and program will not produce any error.


Sanjay Kumar
B.Tech Final Year
Department of Computer Engineering
National Institute of Technology Kurukshetra
Kurukshetra - 136119
Haryana, India



On Tue, Aug 16, 2011 at 8:19 AM, rohit raman.u...@gmail.com wrote:

 #includestdio.hconst char *fun();
 int main()
 {
 char *ptr = fun();
 return 0;
 }const char *fun()
 {
 return Hello;
 }


 Why doesn't this code give error??

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To view this discussion on the web visit
 https://groups.google.com/d/msg/algogeeks/-/qeUTNwGNKfwJ.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Algorithms For Interviews

2011-08-16 Thread siddharth srivastava
On 16 August 2011 20:36, Yogesh Yadav medu...@gmail.com wrote:

 plz upload it againi cant open it...



if you search the group wisely (though not legal) or internet with a bit of
patient and intelligence, you'll find it with no problem




 On Tue, Aug 16, 2011 at 8:31 PM, Nitin Nizhawan 
 nitin.nizha...@gmail.comwrote:

 sent to you ravi

 On Tue, Aug 16, 2011 at 8:16 PM, ravi kumar ravikumar...@gmail.comwrote:


 heyy nitin.. it says da file izz locked .. can u mail me da buk.. thanx
 in advance

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
Regards
Siddharth Srivastava

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Algorithms For Interviews

2011-08-16 Thread Sanjay Rajpal
@Nitin : Plz send it to me also.


Sanjay Kumar
B.Tech Final Year
Department of Computer Engineering
National Institute of Technology Kurukshetra
Kurukshetra - 136119
Haryana, India

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Algorithms for Interviews

2011-08-16 Thread Sanjay Rajpal
Hi frnds,

Plz send me the book Algorithms for Interview by Adnan Aziz and Amit
Prakash as soon as possible.
I need it urgently.


Sanjay Kumar
B.Tech Final Year
Department of Computer Engineering
National Institute of Technology Kurukshetra
Kurukshetra - 136119
Haryana, India

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks]

2011-08-16 Thread pacific :-)
Whats the take-home salary if you work at TCS or infosys ? also work hours
expected ?

On Mon, Aug 15, 2011 at 12:01 PM, vikas singh shyguy1...@gmail.com wrote:

 TCS also have COBOL project... TCS has every language based project u can
 think of. it's your luck whether you get the latest technology to work with
 or the RETRO...


 On Mon, Aug 15, 2011 at 10:59 AM, vaibhav agrawal agrvaib...@gmail.comwrote:

 Majorly software maintainence


 On Mon, Aug 15, 2011 at 12:17 AM, siddharth srivastava 
 akssps...@gmail.com wrote:



 On 15 August 2011 00:15, sukran dhawan sukrandha...@gmail.com wrote:

 do they recruit software engineers for maintainenance?



 yes..and major chunk of projects are maintenance only



 On Mon, Aug 15, 2011 at 12:10 AM, siddharth srivastava 
 akssps...@gmail.com wrote:



 On 15 August 2011 00:03, sukran dhawan sukrandha...@gmail.com wrote:

 hmmm k

 or even purely maintenance jobs where you may not get chance to code at
 all



 On Sun, Aug 14, 2011 at 11:47 PM, rashmi i rash...@gmail.com wrote:

 Infosys and TCS are consultancies. So, the type of job is not fixed.
 It depends on the type of project a client provides, so it may involve
 variety of technologies from C to Java , Perl,etc.


 On Sun, Aug 14, 2011 at 11:31 PM, sukran dhawan 
 sukrandha...@gmail.com wrote:

  can anyone tell me what is the job provided by infosys and tcs?
 IF they do so much mass recruitment what kinda job the ppl get der?

 --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 R@$!-!
 DoN'T LimIt Ur cHaLlEngeS, ChAlLenGe uR LImItS.

  --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Regards
 Siddharth Srivastava



   --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Regards
 Siddharth Srivastava


   --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Thanks and Regards
 VIKAS SINGH
 MCA- final year
 NIT DURGAPUR
 email:
  vikas.singh1...@gmail.com
  shyguy1...@gmail.com
 http://smrit.wordpress.com


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
regards,
chinna.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: Memory Leak

2011-08-16 Thread SAMMM
Will It show the line number where the memory leak is present ???

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] how to find triangular property

2011-08-16 Thread Raghavan
A zero-indexed array *A* consisting of *N* integers is given. A triplet (*P*
, *Q*, *R*) is triangular if [image: $0 \leq P  Q  R  N$] and
*A*[*P*] + *A*[*Q*]  *A*[*R*],
*A*[*Q*] + *A*[*R*]  *A*[*P*],
*A*[*R*] + *A*[*P*]  *A*[*Q*].

For example, consider array *A* such that

A[0] = 10A[1] = 2A[2] =  5
A[3] =  1A[4] = 8A[5] = 20

Triplet (0, 2, 4) is triangular.

-- 
Thanks and Regards,
Raghavan KL

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] GSOC

2011-08-16 Thread Gaurav Menghani
Wrong place

On Tue, Aug 16, 2011 at 7:58 PM, dilip makwana dilipmakwa...@gmail.com wrote:
 Ya please some one share info regarding this .
 @saurabh thanks for askin this 

 On 16 August 2011 19:00, saurabh chhabra saurabh131...@gmail.com wrote:

 can anyone help me in preparing for GSOC(Summer of Code),2012?
 Please give me a description of what exactly it is and what all we
 need to know to get selected in it.
 kindly throw some light.

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Dilip Makwana
 VJTI
 BTech Computers Engineering
 2009-2013

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
Gaurav Menghani

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Memory Leak

2011-08-16 Thread oldman
if you use visual studio,  try visual leak detectorhttp://vld.codeplex.com/,
 it can print callstack used for memory allocation led to every mem leak
block. certainly it can show the line number, in fact, you can double click
the callstack result to jump to the source line.
Have a try, I highly recommend it.

On Tue, Aug 16, 2011 at 11:33 PM, SAMMM somnath.nit...@gmail.com wrote:

 Will It show the line number where the memory leak is present ???

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.



-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks]

2011-08-16 Thread sukran dhawan
25 k i think

On Tue, Aug 16, 2011 at 8:53 PM, pacific :-) pacific4...@gmail.com wrote:

 Whats the take-home salary if you work at TCS or infosys ? also work hours
 expected ?


 On Mon, Aug 15, 2011 at 12:01 PM, vikas singh shyguy1...@gmail.comwrote:

 TCS also have COBOL project... TCS has every language based project u can
 think of. it's your luck whether you get the latest technology to work with
 or the RETRO...


 On Mon, Aug 15, 2011 at 10:59 AM, vaibhav agrawal 
 agrvaib...@gmail.comwrote:

 Majorly software maintainence


 On Mon, Aug 15, 2011 at 12:17 AM, siddharth srivastava 
 akssps...@gmail.com wrote:



 On 15 August 2011 00:15, sukran dhawan sukrandha...@gmail.com wrote:

 do they recruit software engineers for maintainenance?



 yes..and major chunk of projects are maintenance only



 On Mon, Aug 15, 2011 at 12:10 AM, siddharth srivastava 
 akssps...@gmail.com wrote:



 On 15 August 2011 00:03, sukran dhawan sukrandha...@gmail.comwrote:

 hmmm k

 or even purely maintenance jobs where you may not get chance to code
 at all



 On Sun, Aug 14, 2011 at 11:47 PM, rashmi i rash...@gmail.comwrote:

 Infosys and TCS are consultancies. So, the type of job is not fixed.
 It depends on the type of project a client provides, so it may involve
 variety of technologies from C to Java , Perl,etc.


 On Sun, Aug 14, 2011 at 11:31 PM, sukran dhawan 
 sukrandha...@gmail.com wrote:

  can anyone tell me what is the job provided by infosys and tcs?
 IF they do so much mass recruitment what kinda job the ppl get der?

 --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 R@$!-!
 DoN'T LimIt Ur cHaLlEngeS, ChAlLenGe uR LImItS.

  --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Regards
 Siddharth Srivastava



   --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Regards
 Siddharth Srivastava


   --
 You received this message because you are subscribed to the Google
 Groups Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 Thanks and Regards
 VIKAS SINGH
 MCA- final year
 NIT DURGAPUR
 email:
  vikas.singh1...@gmail.com
  shyguy1...@gmail.com
 http://smrit.wordpress.com


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 regards,
 chinna.

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 

[algogeeks] Re: mcq-os

2011-08-16 Thread nivedita arora
hey yar whch book are you doing for OS mcq ??


On Aug 15, 6:07 pm, Kamakshii Aggarwal kamakshi...@gmail.com wrote:
 I am confused about the race around..according  to me it should be included
 with other options,but in the book which i am referring its not included..

 On Mon, Aug 15, 2011 at 6:35 PM, rajeev bharshetty 
 rajeevr...@gmail.comwrote:









  All the above 1,2,3
  Semaphores help to prevent race conditions in a program.
  They help in process synchronization by allowing multiple processes access
  to a common shared memory .
  and they also solve the problem of mutual exclusion allowing only a single
  process in a critical region at a time.

  Correct me if i am wrong.

  On Mon, Aug 15, 2011 at 6:29 PM, Kamakshii Aggarwal kamakshi...@gmail.com
   wrote:

  semaphores are used to solve the problem of?
  1.process synchronization
  2.race around
  3.mutual exclusion.

  --
  Regards,
  Kamakshi
  kamakshi...@gmail.com

  --
  You received this message because you are subscribed to the Google Groups
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

  --
  Regards
  Rajeev N B http://www.opensourcemania.co.cc

  *Winners Don't do Different things , they do things Differently*

   --
  You received this message because you are subscribed to the Google Groups
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

 --
 Regards,
 Kamakshi
 kamakshi...@gmail.com

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: mcq-os

2011-08-16 Thread Kamakshii Aggarwal
the one which rajeev posted..

On Tue, Aug 16, 2011 at 8:00 PM, nivedita arora vivaciousnived...@gmail.com
 wrote:

 hey yar whch book are you doing for OS mcq ??


 On Aug 15, 6:07 pm, Kamakshii Aggarwal kamakshi...@gmail.com wrote:
  I am confused about the race around..according  to me it should be
 included
  with other options,but in the book which i am referring its not
 included..
 
  On Mon, Aug 15, 2011 at 6:35 PM, rajeev bharshetty rajeevr...@gmail.com
 wrote:
 
 
 
 
 
 
 
 
 
   All the above 1,2,3
   Semaphores help to prevent race conditions in a program.
   They help in process synchronization by allowing multiple processes
 access
   to a common shared memory .
   and they also solve the problem of mutual exclusion allowing only a
 single
   process in a critical region at a time.
 
   Correct me if i am wrong.
 
   On Mon, Aug 15, 2011 at 6:29 PM, Kamakshii Aggarwal 
 kamakshi...@gmail.com
wrote:
 
   semaphores are used to solve the problem of?
   1.process synchronization
   2.race around
   3.mutual exclusion.
 
   --
   Regards,
   Kamakshi
   kamakshi...@gmail.com
 
   --
   You received this message because you are subscribed to the Google
 Groups
   Algorithm Geeks group.
   To post to this group, send email to algogeeks@googlegroups.com.
   To unsubscribe from this group, send email to
   algogeeks+unsubscr...@googlegroups.com.
   For more options, visit this group at
  http://groups.google.com/group/algogeeks?hl=en.
 
   --
   Regards
   Rajeev N B http://www.opensourcemania.co.cc
 
   *Winners Don't do Different things , they do things Differently*
 
--
   You received this message because you are subscribed to the Google
 Groups
   Algorithm Geeks group.
   To post to this group, send email to algogeeks@googlegroups.com.
   To unsubscribe from this group, send email to
   algogeeks+unsubscr...@googlegroups.com.
   For more options, visit this group at
  http://groups.google.com/group/algogeeks?hl=en.
 
  --
  Regards,
  Kamakshi
  kamakshi...@gmail.com

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
Regards,
Kamakshi
kamakshi...@gmail.com

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: Probability Puzzle

2011-08-16 Thread Jacob Ridley
I think there is some ambiguity in the question.

 (All this time you don't know you were tossing a fair coin or not).
1) Does the above statement mean that the thower don't know whether he
or she threw a fair coin even after throwing? Or is the thrower not
informed beforehand that one of them is not a fair coin?
2) Does the coin count reduce after every throw or should it be put
back?
3) Depending on 1) and 2), there will be different answers.


On Aug 9, 12:13 am, Maddy madhu.mitha...@gmail.com wrote:
 I think the answer is 17/80, because
 as you say the 5 trials are independent.. but
 the fact that a head turns up in all the 5 trials, give some
 information about our original probability of choosing the coins.

 in case we had obtained a tail in the first trial, we can be sure its
 the fair coin, and so the consecutive trials would become
 independent..

 but since that is not the case, every head is going to increase the
 chance of choosing the biased coin(initially), and hence affect the
 probability of the next head..

 before the first trial probability of landing a head is 3/5, but once
 u see the first head, the probability of landing a head on the second
 trial changes to 4/5*1/4+1/5, and so on..that is, there is a higher
 probability that we chose a biased coin, rather than the fair coin.

 hope its clear..

 On Aug 7, 11:36 pm, sumit gaur sumitgau...@gmail.com wrote:



  (3/5)

  On Aug 7, 10:34 pm, Algo Lover algolear...@gmail.com wrote:

   A bag contains 5 coins. Four of them are fair and one has heads on
   both sides. You randomly pulled one coin from the bag and tossed it 5
   times, heads turned up all five times. What is the probability that
   you toss next time, heads turns up. (All this time you don't know you
   were tossing a fair coin or not).- Hide quoted text -

 - Show quoted text -

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: Testcases

2011-08-16 Thread Jacob Ridley
Another important test case:
Are all the three values greater than 0? Because negative or zero
length values is not allowed for a side of any triangle.

On Jul 29, 11:34 pm, Maddy madhu.mitha...@gmail.com wrote:
 If the three sides are a,b,c

 1. sum of length of any two sides of a triangle, always exceeds the
 third side. So, this can be taken as the first test case, to see if
 a,b,c form a triangle.
 2.if any of the two sides a,b,c are equal- its isoceles triangle
 3.in an obtuse triangle, sum of square of 2 sides should be less than
 the third side
 4. if a, b and c are all different, then it is a scalene triangle.

 for the duster case, I think this might 
 helphttp://www.geekinterview.com/question_details/29384

 On Jul 29, 2:36 am, Umer Farooq the.um...@gmail.com wrote:



  Is that from a phone interview of MS? :-|

  On Fri, Jul 29, 2011 at 2:32 PM, Puneet Gautam 
  puneet.nsi...@gmail.comwrote:

   Hey everyone , pls tell me how testcases of following:

   1. 3 sides of a triangle are taken, output whether its obstuse,
   scalene,isosceles..?
   2. testcases of a duster...

   I know nothing about testcases, so pls reply accordingly..!!

   --
   You received this message because you are subscribed to the Google Groups
   Algorithm Geeks group.
   To post to this group, send email to algogeeks@googlegroups.com.
   To unsubscribe from this group, send email to
   algogeeks+unsubscr...@googlegroups.com.
   For more options, visit this group at
  http://groups.google.com/group/algogeeks?hl=en.

  --
  Umer- Hide quoted text -

 - Show quoted text -

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: Memory Leak

2011-08-16 Thread Jacob Ridley
There is nothing like a single tool to detect memory leaks. Use WinDbg-
UMDH to find which stack/line is leaking memory or making more
allocations.

On Aug 15, 3:03 am, SAMMM somnath.nit...@gmail.com wrote:
 How to detect in which line the Memory Leak has occured ?? I want the
 line number where the Memory leak occurs ??? Give every wild answer u
 can think off 

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: Memory Leak

2011-08-16 Thread Jacob Ridley
Use WinDbg-UMDH to find which stack is making more allocations.

On Aug 15, 3:03 am, SAMMM somnath.nit...@gmail.com wrote:
 How to detect in which line the Memory Leak has occured ?? I want the
 line number where the Memory leak occurs ??? Give every wild answer u
 can think off 

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Memory Leak

2011-08-16 Thread rajeev bharshetty
You can refer http://www.linuxjournal.com/article/6556
and

http://msdn.microsoft.com/en-us/library/ms859415.aspx

Quote from MSDN :
***Basically, you can spot a memory leak when you detect an unexplained
increase in either committed system memory—memory used by various
applications—or in memory owned by a specific application. There are several
approaches to take for checking the current memory situation, as follows:
. *

   - *Run the mi command. At the cesh prompt, type mi. This command
   generates a list of memory usages for each running application. In the Page
   Summary line specified for each application, you will see “r/w=” followed
   immediately by a number. This number indicates the number of allocated pages
   of memory for the indicated application. If this number is unexpected or has
   grown unexpectedly, you may have detected a memory leak in the indicated
   application.*


On Tue, Aug 16, 2011 at 10:56 PM, Jacob Ridley jridley2...@gmail.comwrote:

 Use WinDbg-UMDH to find which stack is making more allocations.

 On Aug 15, 3:03 am, SAMMM somnath.nit...@gmail.com wrote:
  How to detect in which line the Memory Leak has occured ?? I want the
  line number where the Memory leak occurs ??? Give every wild answer u
  can think off 

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
Regards
Rajeev N B http://www.opensourcemania.co.cc

*Winners Don't do Different things , they do things Differently*

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Re: find numbers whose difference is min

2011-08-16 Thread Ankuj Gupta
we take the difference with the maximum element found so far. So we
need to keep track of 2 things:
1) Minimum difference found so far (min_diff).
2) Maximum number visited so far (max_element).
min_diff=abs(a[0]-a[1]);
max_elem=a[0]
for(i=1;iarr_size;i++)
if(abs(max_elem-a[i])min_diff)
  min_diff = abs(max_elem-a[i]);
if(a[i]max_elem)
  max_elem=a[i];

Ankuj
On Aug 16, 7:26 pm, Shuaib Khan aries.shu...@gmail.com wrote:
 Dave, I agree. :)









 On Tue, Aug 16, 2011 at 6:33 PM, Dave dave_and_da...@juno.com wrote:
  @Shuaib: We are talking about an array of numbers, arent't we? It is
  natural to assume that the numbers fall into one of the defined data
  types.

  Dave

  On Aug 16, 4:23 am, Shuaib aries.shu...@gmail.com wrote:
   Yes it will work in this specific case. What I meant was that Radix sort
  isn't always applicable in general to achieve linear time sorting. Its
  complexity isn't exactly O(N) rather O(d*N) where d is the number of bytes
  each of our item consumes. So if the elements in array aren't from a finite
  range, that would be an issue.

   Correct me if I am wrong.

   --
   Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/

   On 16-Aug-2011, at 11:05 AM, Dave dave_and_da...@juno.com wrote:

@Shuaib: It will work in all cases. If you don't think so, give a
counterexample.

Dave

On Aug 16, 12:50 am, Shuaib aries.shu...@gmail.com wrote:
That will work but not in all cases as radix sort isn't a generalized
  sorting algorithm, is it? :)

--
Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/

On 16-Aug-2011, at 10:10 AM, Dave dave_and_da...@juno.com wrote:

@Shuaib: You could sort the numbers in O(n) with a radix sort, and
then finding the min is easy. Mind you, the radix sort might be
  slower
than an O(n log n) sort, but still it satisfies the O(n) constraint.

Dave

On Aug 15, 8:41 pm, Shuaib aries.shu...@gmail.com wrote:
That won't work. And I don't think an O(n) solution is possible.

--
Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/

On 16-Aug-2011, at 6:25 AM, sukran dhawan sukrandha...@gmail.com
  wrote:

find the minimum of two numbers in a loop o(n) and subtract the two

On Tue, Aug 16, 2011 at 6:13 AM, Brijesh Upadhyay 
  brijeshupadhyay...@gmail.com wrote:
Algorithm to find the two numbers whose difference is minimum among
  the set of numbers. For example the sequence is 5, 13, 7, 0, 10, 20, 1, 15,
  4, 19 The algorithm should return min diff = 20-19 = 1. Constraint - Time
  Complexity O(N)

--
You received this message because you are subscribed to the Google
  Groups Algorithm Geeks group.
To view this discussion on the web visithttps://
  groups.google.com/d/msg/algogeeks/-/U8gTWUISJn8J.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group athttp://
  groups.google.com/group/algogeeks?hl=en.

--
You received this message because you are subscribed to the Google
  Groups Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group athttp://
  groups.google.com/group/algogeeks?hl=en.

--
You received this message because you are subscribed to the Google
  Groups Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group athttp://
  groups.google.com/group/algogeeks?hl=en.

--
You received this message because you are subscribed to the Google
  Groups Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group athttp://
  groups.google.com/group/algogeeks?hl=en.

  --
  You received this message because you are subscribed to the Google Groups
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

 --
 Shuaibhttp://www.bytehood.comhttp://twitter.com/ShuaibKhan

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] MICROSOFT RESEARCH INTERN

2011-08-16 Thread arvind kumar
Please explain..how do the interviews differ basically,and what about
the written round?
Regards
Arvind

On 8/16/11, pacific :-) pacific4...@gmail.com wrote:
 Its different.

 There are separate kind of interviews for both looking for different things.

 On Tue, Aug 16, 2011 at 5:18 PM, arvind kumar arvindk...@gmail.com wrote:

 Hi friends
 Can anyone please tell me about microsoft research intern-the
 selection process??
 Is it the same or is it different from microsoft itc??

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --
 regards,
 chinna.

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.



-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: find numbers whose difference is min

2011-08-16 Thread SAMM
I think.i hv seen this code somewhere ..geeksforgeek may be

On 8/16/11, Ankuj Gupta ankuj2...@gmail.com wrote:
 we take the difference with the maximum element found so far. So we
 need to keep track of 2 things:
 1) Minimum difference found so far (min_diff).
 2) Maximum number visited so far (max_element).
 min_diff=abs(a[0]-a[1]);
 max_elem=a[0]
 for(i=1;iarr_size;i++)
 if(abs(max_elem-a[i])min_diff)
   min_diff = abs(max_elem-a[i]);
 if(a[i]max_elem)
   max_elem=a[i];

 Ankuj
 On Aug 16, 7:26 pm, Shuaib Khan aries.shu...@gmail.com wrote:
 Dave, I agree. :)









 On Tue, Aug 16, 2011 at 6:33 PM, Dave dave_and_da...@juno.com wrote:
  @Shuaib: We are talking about an array of numbers, arent't we? It is
  natural to assume that the numbers fall into one of the defined data
  types.

  Dave

  On Aug 16, 4:23 am, Shuaib aries.shu...@gmail.com wrote:
   Yes it will work in this specific case. What I meant was that Radix
   sort
  isn't always applicable in general to achieve linear time sorting. Its
  complexity isn't exactly O(N) rather O(d*N) where d is the number of
  bytes
  each of our item consumes. So if the elements in array aren't from a
  finite
  range, that would be an issue.

   Correct me if I am wrong.

   --
   Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/

   On 16-Aug-2011, at 11:05 AM, Dave dave_and_da...@juno.com wrote:

@Shuaib: It will work in all cases. If you don't think so, give a
counterexample.

Dave

On Aug 16, 12:50 am, Shuaib aries.shu...@gmail.com wrote:
That will work but not in all cases as radix sort isn't a
generalized
  sorting algorithm, is it? :)

--
Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/

On 16-Aug-2011, at 10:10 AM, Dave dave_and_da...@juno.com wrote:

@Shuaib: You could sort the numbers in O(n) with a radix sort, and
then finding the min is easy. Mind you, the radix sort might be
  slower
than an O(n log n) sort, but still it satisfies the O(n)
constraint.

Dave

On Aug 15, 8:41 pm, Shuaib aries.shu...@gmail.com wrote:
That won't work. And I don't think an O(n) solution is possible.

--
Shuaibhttp://twitter.com/ShuaibKhanhttp://www.bytehood.com/

On 16-Aug-2011, at 6:25 AM, sukran dhawan
sukrandha...@gmail.com
  wrote:

find the minimum of two numbers in a loop o(n) and subtract the
two

On Tue, Aug 16, 2011 at 6:13 AM, Brijesh Upadhyay 
  brijeshupadhyay...@gmail.com wrote:
Algorithm to find the two numbers whose difference is minimum
among
  the set of numbers. For example the sequence is 5, 13, 7, 0, 10, 20, 1,
  15,
  4, 19 The algorithm should return min diff = 20-19 = 1. Constraint -
  Time
  Complexity O(N)

--
You received this message because you are subscribed to the
Google
  Groups Algorithm Geeks group.
To view this discussion on the web visithttps://
  groups.google.com/d/msg/algogeeks/-/U8gTWUISJn8J.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group athttp://
  groups.google.com/group/algogeeks?hl=en.

--
You received this message because you are subscribed to the
Google
  Groups Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group athttp://
  groups.google.com/group/algogeeks?hl=en.

--
You received this message because you are subscribed to the Google
  Groups Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group athttp://
  groups.google.com/group/algogeeks?hl=en.

--
You received this message because you are subscribed to the Google
  Groups Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group athttp://
  groups.google.com/group/algogeeks?hl=en.

  --
  You received this message because you are subscribed to the Google
  Groups
  Algorithm Geeks group.
  To post to this group, send email to algogeeks@googlegroups.com.
  To unsubscribe from this group, send email to
  algogeeks+unsubscr...@googlegroups.com.
  For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

 --
 Shuaibhttp://www.bytehood.comhttp://twitter.com/ShuaibKhan

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For 

Re: [algogeeks] Re: find numbers whose difference is min

2011-08-16 Thread Anurag Narain
@ankuj:

i think the solution is not correct..

could u please explain ur algo for

5,13,7,0,10,20,1,15,4,18

acc to ur algo answer is 2 but it should be 1(1-0)

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] c++ templates

2011-08-16 Thread SANDEEP CHUGH
yeah it will be created...  so code size will be the same.. only benefit  of
templates is clearer understanding and u dnt hav to write code , as compiler
does it for you

On Tue, Aug 16, 2011 at 11:51 PM, priya ramesh 
love.for.programm...@gmail.com wrote:

 Please Explain the working of templates in c++.
 for a template like
 template Class t
 T sum (T n1, T n2){
 return n1+n2;
 }

 Will a separate function like
 int sum (int , int)
 be created when it is instantiated with an integer??

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] c++ templates

2011-08-16 Thread priya ramesh
@sandeep : thank you :)

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] c++

2011-08-16 Thread priya ramesh
Plz send good c++ interview questions/resources.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] c++ templates

2011-08-16 Thread SANDEEP CHUGH
:)

On Tue, Aug 16, 2011 at 11:57 PM, priya ramesh 
love.for.programm...@gmail.com wrote:

 @sandeep : thank you :)

  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] c++ multi dimensional arrays

2011-08-16 Thread priya ramesh
Why should the column size be mandatorily passed to a function which expects
a multi dimensional array

int arr (int marray[][5], int rows);
int arr (int marray[][], int rows, int cols);

1st is valid whereas second is invalid. why??

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] reason

2011-08-16 Thread pacific :-)
I believe you are assuming little endian right ?

On Mon, Aug 15, 2011 at 2:14 PM, programming love 
love.for.programm...@gmail.com wrote:

 The internal representation of array is this:

 suppose that the address starts from decimal number 10 and integer occupies
 2 bytes

 10- 0002 ( num 2 in hex)
 12- 0003 ( num 3 in hex)
 14- 0004 ( num 4 in hex)

 Now p points to address 10 and is type char. (Even after type casts) p+1
 will increment address by 1 byte (since it's char). p will now point to 11
 (int *) will say that when de-referenced 2 bytes should be extracted. So the
 2 bytes extracted are 11, 12. Numbers in these bytes are 02 and 00

 10- 00*02* ( num 2 in hex)
 12- *00*03 ( num 3 in hex)
 14- 0004 ( num 4 in hex)

 now (char *) says extract 1 byte for me. The extracted byte is 00. Hence 0
 is printed

 *Correct me if i am wrong.*


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
regards,
chinna.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Algorithm

2011-08-16 Thread atul purohit
@Pramod  Nice work. Although I think Carrot  = 100 - percentage and Stick =
percentage will work instead of the current values.

On Tue, Aug 16, 2011 at 1:13 AM, PramodP p.pramod.n...@gmail.com wrote:

 Here is a modified function that finds the element that crosses a
 particular percentage in an array. Please note that the code returns a false
 value if there is no number that appears more frequently than the input
 percentage. Loop through the array in O(n) and ensure that num indeed is an
 acceptable answer.

 int getNumCrossingPercentage ( Array arr, int percentage) {

   int carrot = percentage; // Positive marks for the
 current number if it matches the current candidate maxfreq number
   int stick = 100 - percentage;  // Negative marks if it
 doesn't match the maxFreq number
 int A[n], i,  num, freq=0;

 set num = A[0] and freq= 1; // assume first number to be the n/2 times
 occurring element.

 from i=1 to n-1
 {
  if (A[i] == num)
 freq += carrot;
  else
 freq -= stick;

  freq = (freq  0)? 0: freq; // in case freq. goes negative.

  if (freq == 0) // That means there might be any other element occurring
 more than the current element.
num = A[i];
 }

 if (!freq) return NULL;

 //TODO: Loop through the array again and check if num indeed does appear in
 the input percentage.
 // and only then return num, else return NULL again.
 if (freq)
  return num;
 else
  return NULL;

 }

 On Mon, Aug 15, 2011 at 7:21 PM, Dipankar Patro dip10c...@gmail.comwrote:

 For n/2 I came across a nice algo sometime back.
 here is how to do it (I am providing algo):

 int A[n], i,  num, freq=0;

 set num = A[0] and freq= 1; // assume first number to be the n/2 times
 occurring element.

 from i=1 to n-1
 {
  if (A[i] == num)
 freq++;
  else
 freq--;

  freq = (freq  0)? 0: freq; // in case freq. goes negative.

  if (freq == 0) // That means there might be any other element occurring
 more than the current element.
num = A[i];
 }

 if (freq)
  return num;
 else
  return NULL;

 How does it work:

 consider this array: 9 , 9 ,1 ,1 ,5 ,1 ,1 ,9 ,1 (n = 9, n/2 = 4)
 - for 1 to be the answer, its freq should be 5 or more.
 - now if 1 has occurred for 5 times, means 4 times some other number has
 occurred (irrespective of how many times other numbers have occurred). so
 the overall extra occurrence is of 1 is 1.
 run the algo (i = 1 to 8):
 - i = 1 , A[i] = 9, n = 9, freq = 1 = freq++;
 - i = 2 , A[i] = 1, n = 9, freq = 2 = freq --;
 - i = 3,  A[i] = 1, n = 9, freq = 1 = freq -- and n is set to 1
 continue till end and you will find that for n = 1, freq = 1;
 so the answer will be 1.

 please do tell me if you find some test case for which above algo fails.

 Will be looking for a similar soln. for n/4.


 On 15 August 2011 16:31, contiguous priyadee...@gmail.com wrote:

 Design an algorithm to find all elements that appear more than n/2
 times in the list. Then do it for elements that appear more than n/4
 times.

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




 --

 ___

 Please do not print this e-mail until urgent requirement. Go Green!!
 Save Papers = Save Trees

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


  --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 

Atul Purohit

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] c++ multi dimensional arrays

2011-08-16 Thread pacific :-)
In memory arrays are stored in row major ordering.If you dont provide the
column size then the system cannot make any access to any of the location in
the array.
when you actually look for the value at a[4][2] what the system does is that
it computes the location as  (4 * column_size + 2 ) * (int size ) and then
makes the reference a[ new_address ].So if you dont provide the column_size
it cannot perform the above operation.Try thinking how would you go about
doing that with out column_size for a[4][2] ? Not possible.

When you do int * * a , you dont need because a + 1 automatically moves to
the next row without the need of column size.Here it is because the
underlying implementation is pointer to pointer and it increments
accordingly to the next row but not next element in the same row when you do
a + 1.

Let me know if im wrong anywhere in my explanation.

On Wed, Aug 17, 2011 at 12:04 AM, priya ramesh 
love.for.programm...@gmail.com wrote:

 Why should the column size be mandatorily passed to a function which
 expects a multi dimensional array

 int arr (int marray[][5], int rows);
 int arr (int marray[][], int rows, int cols);

 1st is valid whereas second is invalid. why??

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
regards,
chinna.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Probability Puzzle

2011-08-16 Thread pacific :-)
I'm little late but I too got 17/18.

On Tue, Aug 16, 2011 at 10:47 PM, Jacob Ridley jridley2...@gmail.comwrote:

 I think there is some ambiguity in the question.

  (All this time you don't know you were tossing a fair coin or not).
 1) Does the above statement mean that the thower don't know whether he
 or she threw a fair coin even after throwing? Or is the thrower not
 informed beforehand that one of them is not a fair coin?
 2) Does the coin count reduce after every throw or should it be put
 back?
 3) Depending on 1) and 2), there will be different answers.


 On Aug 9, 12:13 am, Maddy madhu.mitha...@gmail.com wrote:
  I think the answer is 17/80, because
  as you say the 5 trials are independent.. but
  the fact that a head turns up in all the 5 trials, give some
  information about our original probability of choosing the coins.
 
  in case we had obtained a tail in the first trial, we can be sure its
  the fair coin, and so the consecutive trials would become
  independent..
 
  but since that is not the case, every head is going to increase the
  chance of choosing the biased coin(initially), and hence affect the
  probability of the next head..
 
  before the first trial probability of landing a head is 3/5, but once
  u see the first head, the probability of landing a head on the second
  trial changes to 4/5*1/4+1/5, and so on..that is, there is a higher
  probability that we chose a biased coin, rather than the fair coin.
 
  hope its clear..
 
  On Aug 7, 11:36 pm, sumit gaur sumitgau...@gmail.com wrote:
 
 
 
   (3/5)
 
   On Aug 7, 10:34 pm, Algo Lover algolear...@gmail.com wrote:
 
A bag contains 5 coins. Four of them are fair and one has heads on
both sides. You randomly pulled one coin from the bag and tossed it 5
times, heads turned up all five times. What is the probability that
you toss next time, heads turns up. (All this time you don't know you
were tossing a fair coin or not).- Hide quoted text -
 
  - Show quoted text -

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
regards,
chinna.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Find the value of a(n)

2011-08-16 Thread Bharat Kul Ratan
Sequence *(ai)* of natural numbers is defined as follows:

   *ai = bi* (for *i = k*)
   *ai = c1ai-1 + c2ai-2 + ... + ckai-k* (for *i  k*)

where *bj* and *cj* are given natural numbers for *1=j=k*. We have to 
compute *an* for given *n* 

We've been given:
*k* - number of elements of *(c)* and *(b)* (*1 = k = 10*)
*b1,...,bk* - *k* natural numbers and *c1,...,ck* - *k* natural numbers all 
are non-negative.
*n* - natural number

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/algogeeks/-/Nwqg3knJxbYJ.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] matrix question ???!!!!!!!!!!??????????

2011-08-16 Thread priya ramesh
are these algos optimal???
*Algo 1*:

no_min_max   =-1
min_row=   max_row=   -1
for(i=0; in; i++)
{
   for(j=0; jn; j++){
 find min, max
 }
   if(minprev_min  max  prev_max){
  no_min_max=i;
  break;
}
  else if(min  prev_min){
   min_row=i;
   }
 else if(maxprev_max){
max_row=i;
  }
}
if(no_min_max!=-1){
i=0;
while(i!=min_row  i!=max_row)
i++;
no_min_max=i;
}

print no_min_max row;


*Algo 2:*

1. Copy elements into a linear array

2. Find min and max. O(n)

3. for(i=0; irows; i++){

serach for min, max in the ith row; O(n)
if (both not found)
break;
}

print the ith row;

Which 1 is better???

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] novell

2011-08-16 Thread altu faltu
please reply on this thread asap

On Tue, Aug 16, 2011 at 6:21 PM, altu faltu altufaltu...@gmail.com wrote:

 can anyone give the paper of novell if it has visited any campus dis
 year??

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.



-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Algorithms For Interviews

2011-08-16 Thread shady
i will create a document and share all the links :)
and one more thing do search the archive before asking for anything
 topic closed  ###


On Tue, Aug 16, 2011 at 8:57 PM, Sanjay Rajpal sanjay.raj...@live.inwrote:

 @Nitin : Plz send it to me also.


 Sanjay Kumar
 B.Tech Final Year
 Department of Computer Engineering
 National Institute of Technology Kurukshetra
 Kurukshetra - 136119
 Haryana, India

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.


-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



[algogeeks] Prime numbers

2011-08-16 Thread Don
I wrote a program to print prime numbers, but it is not very fast. Can
someone help me figure out why?


#include stdio.h

/* This program implements a blindingly fast algorithm
   to find prime numbers, using an elegant recursive method. */
int _(int n, int m, int d, int t=0)
{
int r;
if (t) return d?1+_(n,m,d-1,d):n?_(n-1,m,m,n):0;
for(r=m!=n; d*(tn); ++t)
r = _(n,_(t,m,0,1),d-1)|!_(t,1,t);
return r*n;
}


/*--
  Print primes up to the requested value
*/
int main(int argc, char* argv[])
{
for(int n = 2; n = 1000; n++)
printf(%d is%s prime\n,n, _(n,1,n,0)?: not);

return 0;
}

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Prime numbers

2011-08-16 Thread sandeep pandey
try to implement sieve.
it,s a well known algorithm to find out d prime frequently.

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Number theory

2011-08-16 Thread Bharat Kul Ratan
It might be useful:
http://www.artofproblemsolving.com/Wiki/index.php/Partition_%28combinatorics%29

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/algogeeks/-/hymA4xyvdz4J.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: array question

2011-08-16 Thread saurabh singh
+1 to dave.xor is the way to go.

On Tue, Aug 16, 2011 at 7:06 PM, Dave dave_and_da...@juno.com wrote:

 @Raghavan: But aren't maps implemented as binary search trees? That
 would make insertion and searching O(log n), and the overall operation
 O(n log n).

 Dave

 On Aug 16, 4:08 am, Raghavan its...@gmail.com wrote:
  @sukran:
  If you were asking for the map based solution
 
  space and time complexity would be o(n).
 
  On Tue, Aug 16, 2011 at 2:34 PM, sukran dhawan sukrandha...@gmail.com
 wrote:
 
 
 
 
 
   what is the complexity in which it has been done ?
 
   On Tue, Aug 16, 2011 at 1:41 PM, MAC macatad...@gmail.com wrote:
 
   Given an array of integers. Each number in the array repeats ODD
 number of
   times, but only 1 number repeated for EVEN number of times. Find that
   number.
 
   --
   thanks
   --mac
 
--
   You received this message because you are subscribed to the Google
 Groups
   Algorithm Geeks group.
   To post to this group, send email to algogeeks@googlegroups.com.
   To unsubscribe from this group, send email to
   algogeeks+unsubscr...@googlegroups.com.
   For more options, visit this group at
  http://groups.google.com/group/algogeeks?hl=en.
 
--
   You received this message because you are subscribed to the Google
 Groups
   Algorithm Geeks group.
   To post to this group, send email to algogeeks@googlegroups.com.
   To unsubscribe from this group, send email to
   algogeeks+unsubscr...@googlegroups.com.
   For more options, visit this group at
  http://groups.google.com/group/algogeeks?hl=en.
 
  --
  Thanks and Regards,
  Raghavan KL

 --
 You received this message because you are subscribed to the Google Groups
 Algorithm Geeks group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.




-- 
Saurabh Singh
B.Tech (Computer Science)
MNNIT ALLAHABAD

-- 
You received this message because you are subscribed to the Google Groups 
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



  1   2   >