Re: [algogeeks] Re: Largest contigious subarray with average greather than k

2012-11-26 Thread Rahul Kumar Patle
>>> } >>> } >>> >>> >>> On Wed, Nov 21, 2012 at 10:07 PM, Sachin Chitale < >>> sachinchital...@gmail.com> wrote: >>> >>>> Hello, >>>> >>>> Algorithm--> >>>> 1. Find out start and e

Re: [algogeeks] Re: Output

2012-11-25 Thread Rahul Kumar Patle
{ >> dosomething(56); >> dosomething(64); >> dosomething(127); >> return 0; >> } >> >> please explain the logic behind the output. >> >> Thanks, >> Rajesh >> > -- > > > -- Thanks and Regards: Rahul Kumar Patle M.T

Re: [algogeeks] Re: Output

2012-11-25 Thread Rahul Kumar Patle
sorry its left shift.. one mistake.. other than this ans is correct.. i have done left shift on 1 by 4 bits that why result became ~(0.1) ignore the right shift i have mentioned.. On Sun, Nov 25, 2012 at 4:48 PM, Rahul Kumar Patle < patlerahulku...@gmail.com> wrote: > @pand

Re: [algogeeks] C o/p adobe

2012-11-15 Thread Rahul Kumar Dubey
e2 with extern then it shows that j nit >>>> defined..how cum file2 knows in which file j is definedfor e.g if i use >>>> extern in file it means that this variable/fxn is defined somewhr else.then >>>> what are those files in which it searches this variable d

Re: [algogeeks] time complexity of gcd euclid algo(recursive)

2012-11-15 Thread Rahul Kumar Dubey
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

Re: [algogeeks] Re: Printing all inversions in an array

2012-11-14 Thread Rahul Kumar Dubey
...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/algogeeks?hl=en. > -- *RAHUL KUMAR DUBEY* *BTech-3rd year * *Computer Science &Engineering * *Motilal Nehru National Institute Of Technology* *Allahabad[211004],UP.* -- You rece

Re: [algogeeks] C o/p adobe

2012-11-14 Thread Rahul Kumar Dubey
eeks" 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://

Re: [algogeeks] using name space std

2012-11-14 Thread Rahul Kumar Dubey
ions, 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@

Re: [algogeeks] Advice needed

2012-11-14 Thread Rahul Kumar Dubey
ause 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.goo

Re: [algogeeks] Re: Informatica written que : C output

2012-10-31 Thread Rahul Kumar Patle
re 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 > ht

[algogeeks] Informatica written que : C output

2012-10-30 Thread Rahul Kumar Patle
t tmp[10] , i; int n = 0; for(i=0;i<9;i++) { tmp[i]=fork(); if(tmp[i]>0) break; else { //count++; printf("Hello"); //printf(" %d -> %d \n" , tmp[i], count); } } } --

Re: [algogeeks] Microsoft Interview Question

2012-10-16 Thread Rahul Kumar Patle
forgeeks.org/archives/24488 >>> section 5/question 2 >>> >>> Write a program to find all the possible paths from a starting point to >>> dest point in a maze(2-D array). >>> >>> ex: 1 0 1 0 >>> 1 1 1 1 >>> 0 1 0 1 >>

[algogeeks] Re: Microsoft Interview Question

2012-10-15 Thread Rahul Kumar Patle
response awaited!!! anyone?? On Sat, Oct 13, 2012 at 12:31 AM, Rahul Kumar Patle < patlerahulku...@gmail.com> wrote: > Pls help to solve this que.. does any one have DP solution for following > que. > > http://www.geeksforgeeks.org/archives/24488 > section 5/question 2 &

[algogeeks] Microsoft Interview Question

2012-10-15 Thread Rahul Kumar Patle
0 0 1 1 If there is a block it’s represented by 0. If there is a path it’s represented by 1. -- Thanks and Regards: Rahul Kumar Patle M.Tech, School of Information Technology Indian Institute of Technology, Kharagpur-721302, India<http://www.iitkgp.ac.in/> Mobile No: +91-8798

Re: [algogeeks] longest palindrome in a string size 2*10^4

2012-09-23 Thread Rahul Kumar Dubey
p://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

Re: [algogeeks] Adobe Written Test - 25 SEPT 2010

2012-09-23 Thread Rahul Kumar Patle
@dave sir: i understand your point, here my solution is only limited to hold the divisor in range of integer.. On Sat, Sep 22, 2012 at 1:41 AM, Dave wrote: > @Rahul: What does this print for n = 193? > > Dave > > On Friday, September 21, 2012 12:14:18 AM UTC-5, Rahul Ku

Re: [algogeeks] Adobe Written Test - 25 SEPT 2010

2012-09-21 Thread Rahul Kumar Patle
ile( temp < n ) { divisor = 10 * divisor + 1; temp = 10 * temp + 1; } printf("%d and %d\n" , divisor, temp); } printf("%d\n", divisor); } On Fri, Sep 21, 2012 at 10:30 AM, Rahul Kumar Patle < patlerahulku...@gmail.com> wrote: > @navin: you have

Re: [algogeeks] Adobe Written Test - 25 SEPT 2010

2012-09-21 Thread Rahul Kumar Patle
>>>> >>>> >>>> >>>> -- >>>> You received this message because you are subscribed to the Google >>>> Groups "Algorithm Geeks" group. >>>> To post to this group, send email to algo...@googlegroups.com. >>

Re: [algogeeks] Data Structure

2012-09-21 Thread Rahul Kumar Patle
> 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.co

Re: [algogeeks] help to give DP solution

2012-09-16 Thread Rahul Kumar Patle
n Sat, Sep 15, 2012 at 9:10 PM, Rahul Kumar Patle < > patlerahulku...@gmail.com> wrote: > >> A 2D array of order A[N][N] is given, considering entry A[i][i] as >> invalid you have to select one element from each row such that >> 1. Selected elements does not belong to

[algogeeks] help to give DP solution

2012-09-15 Thread Rahul Kumar Patle
A 2D array of order A[N][N] is given, considering entry A[i][i] as invalid you have to select one element from each row such that 1. Selected elements does not belong to same column. 2. Sum of selected element has maximal. -- Thanks and Regards: Rahul Kumar Patle<http://www.linkedin.com/prof

Re: [algogeeks] Microsoft written test question

2012-09-06 Thread Rahul Kumar Patle
gt; > *Shashi Kant * > ***"Think positive and find fuel in failure"* > http://thinkndoawesome.blogspot.com/ > *System/Software Engineer* > *Hewlett-Packard India Software Operations. > * > > > > On Tue, Sep 4, 2012 at 1:56 PM, Rahul Kumar Patle < > patlerahulku...@gm

Re: [algogeeks] Microsoft written test question

2012-09-04 Thread Rahul Kumar Patle
norder of given tree is :- > > 20 10 25 50 55 60 65 70 75 > > > > now first violation is at node(20) > > but you wont get second voilation...because rest is in inc order. > > > > yes , it can be done by taking care of root of that first violation. > > &g

Re: [algogeeks] Microsoft written test question

2012-09-03 Thread Rahul Kumar Patle
happens for the second time..then mark current element for swapping. > swap both .. > > If we don't get the violation for the second time .. means both are > side-by-side elements .. swap them .. > > Hope works .. If I miss any case .. correct me > thanks, > > >

Re: [algogeeks] MICROSOFT:Given a BST and a number. Find two node in a BST whose sum is equal to given number in O(n) time and O(1) space.

2012-09-03 Thread Rahul Kumar Patle
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

Re: [algogeeks] Microsoft written test question

2012-09-02 Thread Rahul Kumar Patle
gt; Question: Two of the nodes of a BST are swapped. Correct the BST (taken >> from GeekforGeeks <http://www.geeksforgeeks.org/archives/23272> 2nd >> online test 3rd question) >> >> >> >> >> -- >> Thanks and Regards: >> Rahul Kumar >>

Re: [algogeeks] explain the ouput

2012-09-02 Thread Rahul Kumar Dubey
t; return value of function call On Sun, Sep 2, 2012 at 11:12 AM, RAJAT DUBEY wrote: > @Rahul kumar Dubey > > #include > double fn(char *a , int b , char c) > { > return (1.1); > } > > int main() > { > int it = 2; > char ct = 'c'; > char a[

[algogeeks] Microsoft written test question

2012-09-02 Thread Rahul Kumar Patle
help to solve the following.. Question: Two of the nodes of a BST are swapped. Correct the BST (taken from GeekforGeeks <http://www.geeksforgeeks.org/archives/23272> 2nd online test 3rd question) -- Thanks and Regards: Rahul Kumar Patle<http://www.linkedin.com/profile/view?id=1062

Re: [algogeeks] explain the ouput

2012-09-01 Thread Rahul Kumar Dubey
ay double it will print 8 byte (size of double on your machine ) On Fri, Aug 31, 2012 at 9:25 PM, Rahul Kumar Patle < patlerahulku...@gmail.com> wrote: > #include > #include > > bool fn(char *a , int b , char c) > { > return true; > } > > int main() > { > in

[algogeeks] explain the ouput

2012-09-01 Thread Rahul Kumar Patle
() why?? pls explain.. -- Thanks and Regards: Rahul Kumar Patle<http://www.linkedin.com/profile/view?id=106245716&trk=tab_pro> M.Tech, School of Information Technology Indian Institute of Technology, Kharagpur-721302, India<http://www.iitkgp.ac.in/> Mobile No: +91-8798049298, +91-9424

Re: [algogeeks] file handle

2012-08-18 Thread Rahul Kumar Dubey
oglegroups.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. > > -- *RAHUL KUMAR DUBEY* *BTech-3rd year * *Computer Science &Engineering

[algogeeks] Re: Finding the repeated element

2012-07-23 Thread Rahul Kumar
what is the time complexity for the code ? #include using namespace std; main() { int arr[] = { 2,3,4,9,2,7}; int *ptr1 = &arr[0]; int *ptr2 = &arr[1]; const int SIZE = sizeof arr / sizeof arr[0]; while(1) { if(*ptr1 == *ptr2)

[algogeeks] Re:

2012-07-23 Thread Rahul Kumar
N+=3; print N!-(N^2-1); let me know if I am wrong On Wednesday, 11 July 2012 16:42:38 UTC+5:30, wentworth miller wrote: > > hi .. > can anybody tell the Nth term of the following series... > 9 96 685 4992. > -- You received this message because you are subscribed to the Google Groups "A

[algogeeks] Re: Directi Interview Ques

2012-07-23 Thread Rahul Kumar
> > > http://www.ocf.berkeley.edu/~wwu/cgi-bin/yabb/YaBB.cgi?board=riddles_cs;action=display;num=1280183627 > > -- 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/alg

Re: [algogeeks] Need links for Problem solving interview questions(non DS and algorithmic) probably with how to reach a solution

2012-07-11 Thread Rahul Kumar Patle
oup at > http://groups.google.com/group/algogeeks?hl=en. -- Thanks and Regards: Rahul Kumar Patle M.Tech, School of Information Technology Indian Institute of Technology, Kharagpur-721302, India Mobile No: +91-8798049298, +91-9424738542 -- You received this message because you are subscribed to t

Re: [algogeeks] Datastructure and algorithms book

2012-06-05 Thread Rahul Kumar Patle
subscribe 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: Rahul Kumar Patle M.Tech, School of Information Technology Indian Institute of Technology, Kh

Re: [algogeeks] Re: MS: searching problem......help me out...

2012-06-04 Thread Rahul Kumar Patle
" 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. > > -- Tha

Re: [algogeeks] MS: searching problem......help me out...

2012-06-03 Thread Rahul Kumar Patle
space complexity has increased... you will need one redundant array to use heap operation so that finally you will have original array as it is... Thanks and Regards: Rahul Kumar Patle On Sun, Jun 3, 2012 at 8:31 PM, abhinav gupta wrote: > > We have given a list 14 6 7 15 8 9

Re: [algogeeks] Re: Rectangle area

2012-06-03 Thread Rahul Kumar Patle
Google Groups > "Algorithm Geeks" group. > To view this discussion on the web visit > https://groups.google.com/d/msg/algogeeks/-/wVxBh-kN-LoJ. > > To post to this group, send email to algogeeks@googlegroups.com. > To unsubscribe from this group, send email to > algo

Re: [algogeeks] Re: Rectangle area

2012-06-03 Thread Rahul Kumar Patle
sorry got the que... ignore my last reply.. thanks On Sun, Jun 3, 2012 at 9:49 AM, Rahul Kumar Patle wrote: > @payel : you have mentioned sum of square of diagonal of rectangle.. but > as you can see that 29 can't be the sum of square of diagonal of any > rectangle.. because f

Re: [algogeeks] Required O(n) Algorithm

2012-04-18 Thread Rahul Kumar Patle
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: Rahul Kumar Patle M.Tech,

Re: [algogeeks] decimal to binary..c code....

2012-01-29 Thread Rahul Kumar
ur subject is decimal to binary but in content u have written float to decimal... I don't get it On Sat, Jan 28, 2012 at 11:49 PM, rahul sharma wrote: > it should be able to convert not only int but also float like 190.345 to > decimalcan ny one suggest thnx in advance > > -- > You receiv