Re: [algogeeks] Any book suggestion for Data structure and algo.
or google This : cs170 On 12/17/11, Abhishek Goswami zeal.gosw...@gmail.com wrote: ya Sure Thx bro On Sat, Dec 17, 2011 at 3:15 PM, Rahul raikra...@gmail.com wrote: If you have time then Do a Google this www.algo-class.org On Sat, Dec 17, 2011 at 3:13 PM, Abhishek Goswami zeal.gosw...@gmail.comwrote: Cool Rahul On Sat, Dec 17, 2011 at 3:09 PM, Rahul raikra...@gmail.com wrote: Google this 6.046 You should not ask any more suggestion till you complete the above On Sat, Dec 17, 2011 at 3:07 PM, Abhishek Goswami zeal.gosw...@gmail.com wrote: -- 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. -- Thanks and Regards, --- *DIPANKAR DUTTA* Software Development Engineer Xen Server - OpenStack Development Team (DataCenter and Cloud) Citrix RD India Pvt Ltd #23 Residency Road, Bangalore - 560 025 Phone: +91 8147830733 Office: Extn: 16429 Email: dipankar.du...@citrix.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: Find the later version
what's happen if the versions are not in same length.. For example v1: 1.1.1.133.2 v2: 1.2 v3: 1.2.3.4..333 v4: 1.2.3.4.5554.222 v5: 1.3.2.2.2.2.2.2.2.2.2.2.2.2 It implies we must be scan from left side one by one ... In general the we make a some sort of lexical comparison where each character is a number and separated by number .. the problem definition is as : let V1,V2,V3 ...Vn be the n version let S={1,2,3...n} ,index=0 Latest[S,index]= return Vi if { Max(ALL Vi[k] where i belongs to S )} is a singleton, else = return Latest[ set of all index belongs to { Max(ALL Vi[k] where i belongs to S )}, index+1 ] On 10/11/11, Dave dave_and_da...@juno.com wrote: @Karen: It is more complicated than scanning character by character. E.g., 1.10.3 is older than 1.9.7. I think you need to parse the numbers between the dots and compare them one by one. Thus, in the above example, 1 compares equal to 1, so you keep scanning. Then 10 compares greater than 9 so the first string is number of the newer version. I did this many years ago in a csh install script for a unix product. Dave On Oct 10, 9:52 pm, bagaria.ka...@gmail.com bagaria.ka...@gmail.com wrote: Given two strings describing the version of a particular software need to find the later version. For eg. 1st string = 1.2.4.5 2nd string=1.2.3.5 1st string is the later one. Can be done using traversing the string and comparing each character one after the another. Looking for a better solution with lesser complexity. -- Thanks and Regards *Karan Bagaria* *MCA Final Year* Training and Placement Representative *NIT Durgapur* -- 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, -- **DIPANKAR DUTTA Software Development Engineer Xen Server - OpenStack Development Team (DataCenter and Cloud) Citrix RD India Pvt Ltd 69/3, Millers Road, Bangalore – 560052 Phone: +91 8147830733 Office: Extn: 16429 Email: dipankar.du...@citrix.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] Given a String with unnecessary spaces, compact it in place
Solution 1: need two scan : start from left and replace one by one by non-space character ( thus have minimal replacemnt) count =0; for (int i=0;ilen(str);i++) { if(str[i] !=NONSPCECHAR) {str[count++]=str[i] } } ps: any way it needs Left shift...and all solution must need left shift if you try to compact it in lower index area. On 10/11/11, abhishek sharma abhishek.p...@gmail.com wrote: Can in place compaction be done without left shifts? -- Nice Day Abhishek Sharma Bachelor of Technology IIT Kanpur (2009) -- 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, -- **DIPANKAR DUTTA Software Development Engineer Xen Server - OpenStack Development Team (DataCenter and Cloud) Citrix RD India Pvt Ltd 69/3, Millers Road, Bangalore – 560052 Phone: +91 8147830733 Office: Extn: 16429 Email: dipankar.du...@citrix.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: which is better?
Depends on compiler architecture , and how they use instruction set architecture ( Increment Op) of underlining machine On Thu, Sep 22, 2011 at 7:21 AM, Don dondod...@gmail.com wrote: If the value of the expression is not being used, ++n is preferred. Most coding standards used by big companies require the prefix operator to be used unless the pre-incremented value is required. Don On Sep 22, 7:54 am, Sahil Garg garg.sahi...@gmail.com wrote: n=n+1 n++ ++n which of the three is better ?? Sahil Garg Computer Engg. DCE -- 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, -- **DIPANKAR DUTTA Software Development Engineer Xen Server - OpenStack Development Team (DataCenter and Cloud) Citrix RD India Pvt Ltd 69/3, Millers Road, Bangalore – 560052 Phone: +91 8147830733 Office: Extn: 16429 Email: dipankar.du...@citrix.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] Book Request
If any one has the follow book, post it.. Data Structures and Algorithms Made Easy Data Structure and Algorithmic Puzzles Authored by Mr Narasimha Karumanchi -- 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 aps can some one explain this pls :)
This depends on how the compiler evaluates the actual parameters and push to the stack when printf is called. this is totally depeding on the compiler architecture [ basically implemetion of activation record in intermediate code genaration phase, read intermidiate language and virtual machine @ compiler design by Aho ullman] In dev C++, the printf works as below: they evalute expression from right to left and push back into stack. thus the expression printf(%d %d %d %d,++p,p++,p++,++p); evaluted as below: initially p=1; printf(%d %d %d %d,++p,p++,p++,2);//p=2 as prefix printf(%d %d %d %d,++p,p++,2,2);//p=3 as postfix printf(%d %d %d %d,++p,3,2,2);//p=4 again postfix printf(%d %d %d %d,5,3,2,2);//p=5 here prefix.. as now our stack contaion 5,3,2,2 ..it print's as this... some more example as : printf(%d %d %d %d %d,++ p,p++,p++,++p, p++); output:6 4 3 3 1 printf(%d %d %d %d %d,++ p,p++,p++,p++, p++); output: 6,4,3,2,1 printf(%d %d %d %d %d,++p,p--,--p,p++, p--); output: 0 0 0 0 1 On 7/18/11, keyan karthi keyankarthi1...@gmail.com wrote: thanks ppl :) On Mon, Jul 18, 2011 at 3:59 PM, schrodinger 6fae1ce6347...@gmail.comwrote: AFAIK, official answer is due to undefined behavior. -- 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/-/EAWuaDE1CIcJ. 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, -- **DIPANKAR DUTTA Software Development Engineer Xen Server - OpenStack Development Team (DataCenter and Cloud) Citrix RD India Pvt Ltd 69/3, Millers Road, Bangalore – 560052 Phone: +91 9045809987 Office: Extn: 16429 Email: dipankar.du...@citrix.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: Number of Comparisons!
plz refer sahani's book of algo..:) On 7/2/11, Dave dave_and_da...@juno.com wrote: @Udit: This can't be correct. For n = 3, it predicts 4-1/2 comparisons. I don't know what half of a comparison is. Three comparisons are all that is required. In fact, for all odd n, it predicts a non-integer number of comparisons. Dave On Jul 2, 3:51 pm, udit sharma sharmaudit...@gmail.com wrote: If n is odd, then we perform 3*n/2 comparisons. If n is even, we perform 1 + 3*(n-2)/2 -- Regards UDIT DU- MCA -- 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, -- **DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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] String Swapping Problem
instead of calling swap(ps[0],ps[1]) can u try with swap(ps[0],ps[1]) or swap(ps[0][0],ps[1][0]) ? On Fri, Jun 17, 2011 at 5:05 AM, udit sharma sharmaudit...@gmail.comwrote: #includestdio.hvoid swap(char *,char *);int main(){char *ps[2]={ Hello, Good Mornning, };swap(ps[0],ps[1]);printf(%s \t %s\n,ps[0],ps[1]);return 0;} void swap(char *p,char *q){char *t;t=p;p=q;q=t;} why the output is: Hello Good Mornning -- Regards UDIT DU- MCA -- 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, -- *DIPANKAR DUTTA* Visiting Research Scholar Dept of Computing, Macquarie University, Sydney, Australia ph.no-+61 2 98509079 ( Mon-Fri 10:15-7:00) Sydney time email: dipankar.du...@mq.edu.au -- 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: Explain the o/p
This is depending on the precission of floating point number representation (IEEE double pression or single precission ) and how it is handled by the compilers) On Thu, Jun 16, 2011 at 8:50 PM, Kamakshii Aggarwal kamakshi...@gmail.comwrote: I have read this link,still i am not getting.Can anybody help?? On 6/16/11, Kamakshii Aggarwal kamakshi...@gmail.com wrote: I have read this link,still my not getting.Can anybody help?? On 6/15/11, Maksym Melnychok keym...@gmail.com wrote: that's floating point for you. http://en.wikipedia.org/wiki/Floating_point -- 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/-/RcduUpABmi8J. 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 -- 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. -- Thanks and Regards, -- *DIPANKAR DUTTA* Visiting Research Scholar Dept of Computing, Macquarie University, Sydney, Australia ph.no-+61 2 98509079 ( Mon-Fri 10:15-7:00) Sydney time email: dipankar.du...@mq.edu.au -- 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] Need an Algorithm Recommendation
I think this can be performed by forming an augumented data strcture (like augmented linked list or BST).. then you can apply the genraral algorithm like sorting searching or graph algo... to performance imporovement you can use cache or has table... On Fri, Jun 17, 2011 at 7:27 AM, Rigo rodrigo.stockebr...@gmail.com wrote: Which algorithm would I use if I had an e-commerce website that captured user data (shopping data, site navigation data, and social media data) and I wanted to come up with a formula that would tell me which products sell best (when they sell best, to whom they sell best, etc...)? Any ideas would be great and much much much appreciated! Thanks, Rodrigo -- 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, -- *DIPANKAR DUTTA* Visiting Research Scholar Dept of Computing, Macquarie University, Sydney, Australia ph.no-+61 2 98509079 ( Mon-Fri 10:15-7:00) Sydney time email: dipankar.du...@mq.edu.au -- 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] help
(this is dependon on compiler implementaion)this is due to shortcircuit implementaion of intermidiate code genaration phase of compiler.. please read Aho ullman book of compiler desgn to get more details. On Wed, Jun 15, 2011 at 12:51 AM, snehi jain snehijai...@gmail.com wrote: first it checks Q if that is NOT true then it computes R else it doesn't. this is the correct line . On Tue, Jun 14, 2011 at 10:21 PM, snehi jain snehijai...@gmail.comwrote: that is what is happening here m = ++i || (++j ++k); in C if P = Q || R; first it checks Q if that is NOT true then it computes C else it doesn't. ++ is a unary operator so before the || and operations can happen increment will take place. This justifies the higher precedence of ++ operator. in the above example i gets incremented to -2 first and then || operation is executed. i has a non-zero value therefore no computation is done for (++j ++k); . keep initial value of i to -1 then after m = ++i || (++j ++k); statement i = 0 , j = 3 , k =1 and m =1 On Tue, Jun 14, 2011 at 10:02 PM, nicks crazy.logic.k...@gmail.comwrote: hmm...someone explain...me too confused :( On Tue, Jun 14, 2011 at 9:14 AM, rahul dixit dixit.rahu...@gmail.comwrote: bt increment operator has the higher precedence than || and so all the variables should be incremented first then and then || should be evaluated then how it is happening.plz explain rahul dixit Du-Mca -- 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. -- Thanks and Regards, -- *DIPANKAR DUTTA* Visiting Research Scholar Dept of Computing, Macquarie University, Sydney, Australia ph.no-+61 2 98509079 ( Mon-Fri 10:15-7:00) Sydney time email: dipankar.du...@mq.edu.au -- 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] Adobe Q
We can optimize the code using DP... On Wed, Jun 15, 2011 at 8:24 PM, immanuel kingston kingston.imman...@gmail.com wrote: The following is for LCA for 2 nodes in a n-ary tree. A more tougher problem is to find the LCA for n nodes in the same n-ary tree. Node * findLCA (Node *root, Node * l, Node * r, int n) { if (l == null || r == null) return root; if (root == null) return null; if (isChild(root,l) || isChild(root, r)) { return root; } Node * arr[n]; int count = 0; Node * notNull; for (int i = 0 ; i n ; i ++ ) { arr[i] = findLCA(root-children[i], l, r); if ( arr[i] != null ) { count ++; notNull = arr[i]; } } if (count == 0) { return null; } else if (count == 2) { return root; } else { return notNull; } } On Wed, Jun 15, 2011 at 2:59 PM, Piyush Sinha ecstasy.piy...@gmail.comwrote: WAP to find the LCA in a n-ary tree. -- *Piyush Sinha* *IIIT, Allahabad* *+91-8792136657* *+91-7483122727* *https://www.facebook.com/profile.php?id=10655377926 * -- 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, -- *DIPANKAR DUTTA* Visiting Research Scholar Dept of Computing, Macquarie University, Sydney, Australia ph.no-+61 2 98509079 ( Mon-Fri 10:15-7:00) Sydney time email: dipankar.du...@mq.edu.au -- 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: Link for sartaj sahni video lectures
http://www.cise.ufl.edu/academics/courses/preview/cop3530sahni/ On Mon, Apr 25, 2011 at 4:59 PM, D.N.Vishwakarma@IITR deok...@gmail.comwrote: No It is not a fake link wait for 5 seconds then pree skip ad button then you will be directed to actual site On Mon, Apr 25, 2011 at 3:13 PM, KK kunalkapadi...@gmail.com wrote: Hey it seems to be a fake link... It directs to some site which shorten URLs -- 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 IITR MCA Mathematics Department* * -- 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, -- *DIPANKAR DUTTA* Visiting Research Scholar Dept of Computing, Macquarie University, Sydney, Australia ph.no-+61 416381145 email: dipankar.du...@mq.edu.au -- 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] Cracking the IT interview: jump start your career with confidence
can Any one have the link of the following book: Cracking the IT interview: jump start your career with confidence By M Balasubramaniam -- Thanks and Regards, -- *DIPANKAR DUTTA* Visiting Research Scholar Dept of Computing, Macquarie University, Sydney, Australia ph.no-+61 416381145 email: dipankar.du...@mq.edu.au -- 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] 60 Tips On Object Oriented Programming By S.G. Ganesh
If Any one has the link of the following book plz share : 60 Tips On Object Oriented Programming By S.G. Ganesh -- Thanks and Regards, -- *DIPANKAR DUTTA* Visiting Research Scholar Dept of Computing, Macquarie University, Sydney, Australia ph.no-+61 416381145 email: dipankar.du...@mq.edu.au -- 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] If anyone have this book please mail me Thanks in advance
http://www.mediafire.com/?692caj1v154c5kc plz be sure that ur network admin nt block mediafire file hosting site.. On Wed, Apr 20, 2011 at 6:55 PM, Subhransu subhransu.panigr...@gmail.comwrote: Could you please mail me the URL/PDF of this. the above link seems not working for me *Subhransu Panigrahi * *Mobile:* *+91-9840931538* *Email:* subhransu.panigr...@gmail.com On Wed, Apr 20, 2011 at 7:22 AM, D.N.Vishwakarma@IITR deok...@gmail.comwrote: *I've already got But thanks for your link * On Wed, Apr 20, 2011 at 5:32 AM, DIPANKAR DUTTA dutta.dipanka...@gmail.com wrote: plz chk the folowing link.. www.*mediafire*.com/?692caj1v154c5kc On Tue, Apr 19, 2011 at 11:05 PM, D.N.Vishwakarma@IITR deok...@gmail.com wrote: Cracking the Coding Interview by *Gayle Laakmannhttp://pothi.com/pothi/search/google?cx=014194668748364006794:ovhp_xhwczgcof=FORID:11query=Gayle%20Laakmannop=Searchform_id=google_cse_searchbox_form * -- **With Regards Deoki Nandan Vishwakarma IITR MCA Mathematics Department* * -- 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, -- DIPANKAR DUTTA Visiting Research Scholar Dept of Computing, Macquarie University, Sydney, Australia ph.no-+61 416381145 email: dipankar.du...@mq.edu.au --- M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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 IITR MCA Mathematics Department* * -- 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, -- *DIPANKAR DUTTA* Visiting Research Scholar Dept of Computing, Macquarie University, Sydney, Australia ph.no-+61 416381145 email: dipankar.du...@mq.edu.au -- 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: C o/p gud one try
printf() is not so much strong in type conversion...it does not able to perform correct type conversion...:) On Thu, Mar 31, 2011 at 1:24 PM, sourabh jakhar sourabhjak...@gmail.comwrote: these kind of question are compiler dependent if you are preparing for interview than these kind of questions are not asked On Tue, Mar 29, 2011 at 10:42 PM, kunal srivastav kunal.shrivas...@gmail.com wrote: refer let us c by YK fr these type of ques On Tue, Mar 29, 2011 at 10:07 PM, ArPiT BhAtNaGaR arpitbhatnagarm...@gmail.com wrote: please do answer geeks me waiting On Mon, Mar 28, 2011 at 11:14 PM, ArPiT BhAtNaGaR arpitbhatnagarm...@gmail.com wrote: #includestdio.h main() { long x; float t; scanf(%f,t); printf(%d\n,t); x=90; printf(%f\n,x); { x=1; printf(%f\n,x); { x=30; printf(%f\n,x); } printf(%f\n,x); } x==9; printf(%f\n,x); } o/p on gcc compiler 20.3 (i/p given) -1073741824 20.299988 20.299988 20.299988 20.299988 20.299988 plz explain the o/p -- Arpit Bhatnagar (MNIT JAIPUR) -- Arpit Bhatnagar (MNIT JAIPUR) -- 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. -- thezeitgeistmovement.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. -- SOURABH JAKHAR,(CSE)(3 year) ROOM NO 167 , TILAK,HOSTEL 'MNNIT ALLAHABAD The Law of Win says, Let's not do it your way or my way; let's do it the best way. -- 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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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] Application N-ary Tree..Important Question As Well
this is something like Multiple granularity locking protocol in DBMS... On Fri, Mar 18, 2011 at 5:43 PM, bittu shashank7andr...@gmail.com wrote: Given an n-ary tree of resources arranged hierarchically. A process needs to lock a resource node in order to use it. But a node cannot be locked if any of its descendant or ancestor is locked. You are supposed to: - write the structure of node - write codes for * Islock()- returns true if a given node is locked and false if it is not * Lock()- locks the given node if possible and updates lock information * Unlock()- unlocks the node and updates information. Codes should be : * Islock –O(1) * Lock()- O(log n) * unLock()- O(log n) Thanks Regards Shashank -- 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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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] nzec
http://discuss.codechef.com/showthread.php?t=635 On Thu, Mar 17, 2011 at 7:11 PM, kavitha nk kavithan...@gmail.com wrote: oh 5n.. -- //BE COOL// kavi -- 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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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] Print Hello infinite..................
@All: it is not possible. as you your target program contain finite number of instraction and execute some instruction many times. what ever tips you are using in your high lavel program must convet to Assembly program contains some GOTO (ultimately all loop converted into JUMP call)or Use stack to execute print statement several time. On Fri, Mar 11, 2011 at 2:14 PM, Abhishek Sharma jkabhishe...@gmail.comwrote: @nidhi: yup.. u r rite.. sorry..my bad... On Thu, Mar 10, 2011 at 11:58 AM, Nishant Agarwal nishant.agarwa...@gmail.com wrote: #includestdio.h void print1(); void print2() { printf(Hello\n); print1(); } void print1() { printf(Hello\n); print2(); } int main() { print1(); } On Thu, Mar 10, 2011 at 11:47 AM, nidhi jain nidhi.jain311...@gmail.comwrote: @abhishek:isn't it recursion? -- 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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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] Find the first K smallest element from 1 million sized array ...Amazon Question..
use heap tree to slove this.. plz see careercup post.. On Wed, Mar 16, 2011 at 10:31 AM, Ankit Sinha akki12...@gmail.com wrote: Asked in Amazon interview.. Find the first K smallest element from 1 million sized array . Assume your ram memory is so small that it cannot accommodate all 1 Million element at once. Guys provide your inputs on the same... Thanks, Ankit -- 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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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: Given an integer n , you have to print all the ways in which n can be represented as sum of positive integers
use DP see careercup.. On Tue, Mar 15, 2011 at 10:43 PM, albert theboss alberttheb...@gmail.comwrote: @bittu : many over lapping sub problems available in ur case ... better try dp to get the efficient solution... @all : suggest algo for the case without repetition. -- 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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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: 10 digit problem
correct On Mon, Mar 14, 2011 at 1:37 PM, bittu shashank7andr...@gmail.com wrote: i don't think another answer 50 is best answer according to your constraints may sum1 else can think but i found its correct Thanks Shashank -- 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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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] Matrix will Stuck..!!!!!!!!
http://dsalgo.blogspot.com/2006/07/maximum-sub-array-sum.html On Fri, Feb 18, 2011 at 2:51 AM, bittu shashank7andr...@gmail.com wrote: you have 2-d array, with m length and n width.You are also given k, ( k=n k=m ). Now, select a square of size k, which returns maximum sum.In Minimum Time Complexity Thanks Regards Shashank. -- 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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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] Matrix will Stuck..!!!!!!!!
http://dsalgo.blogspot.com/2008/05/max-sum-sub-matrix.html On Fri, Feb 18, 2011 at 7:10 PM, DIPANKAR DUTTA dutta.dipanka...@gmail.comwrote: http://dsalgo.blogspot.com/2006/07/maximum-sub-array-sum.html On Fri, Feb 18, 2011 at 2:51 AM, bittu shashank7andr...@gmail.com wrote: you have 2-d array, with m length and n width.You are also given k, ( k=n k=m ). Now, select a square of size k, which returns maximum sum.In Minimum Time Complexity Thanks Regards Shashank. -- 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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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] Matrix will Stuck..!!!!!!!!
Let f[r, c] denote the sum of rectangular subarray ofM with one corner at entry [1, 1] and the other at [r, c]. This can be computed in O(n2) time. Observe that the sum of any rectangular subarray of M can be computed in constant time given the table f. This yields an O(n4) algorithm; simply guess the lower-left and the upper-right corner of the rectangular subarray and use the f table to compute its sum. Here is how we can get O(n3) time. Recall that the maximum sum substring of a 1 dimensional array algorithm simply walks through the array one entry at a time and keeps a running total of the entries. If this total ever becomes negative then set it to 0. Output the largest of these totals. Use this as an auxiliary function to solve the two dimensional problem in the following way. Guess the top and bottom row r1 and r2 of the subarray. Using the table f computed previously and the maximum sum substring algorithm for 1 dimensional arrays we can determine the maximum sum rectangular subarray with top row r1 and bottom row r2 in linear time. On Fri, Feb 18, 2011 at 7:11 PM, DIPANKAR DUTTA dutta.dipanka...@gmail.comwrote: http://dsalgo.blogspot.com/2008/05/max-sum-sub-matrix.html On Fri, Feb 18, 2011 at 7:10 PM, DIPANKAR DUTTA dutta.dipanka...@gmail.com wrote: http://dsalgo.blogspot.com/2006/07/maximum-sub-array-sum.html On Fri, Feb 18, 2011 at 2:51 AM, bittu shashank7andr...@gmail.comwrote: you have 2-d array, with m length and n width.You are also given k, ( k=n k=m ). Now, select a square of size k, which returns maximum sum.In Minimum Time Complexity Thanks Regards Shashank. -- 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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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] Good E-BOOK
Any one has the E- book Algorithms For Interviews by Adnan Aziz. ? It s a good book for algo, please send download link.. thank u in advance -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in -- 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] tic-tac-toe in a distributed environment
1) write a program to play tic-tac-toe in a distributed environment.The two players will be playing from different machines.. 2)write a program for real time video broadcasting by using RTP protocol? could u help me by sending the codes of any of those problem? -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in email%3adipan...@iitr.ernet.in -- 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] random function
read modeling and simulation book it has a great discussion on random number generartion and testing On Mon, Dec 27, 2010 at 11:52 AM, 王大东 dadongk...@gmail.com wrote: Linear congruential sequence maybe a simple approach. A[n]=(a*A[n-1]+b)%c, But it's another problem how to chose a,b,c. On Sat, Dec 25, 2010 at 1:05 PM, Puneet Ginoria punnu.gino...@gmail.comwrote: volume 2 , chapter 3 On Fri, Dec 24, 2010 at 11:13 AM, Puneet Ginoria punnu.gino...@gmail.com wrote: There is a book called The art of computer programming by donald knuth. He had discussed the random function in great detail. On Tue, Dec 21, 2010 at 8:06 PM, snehal jain learner@gmail.comwrote: How do you write your own random function? -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.comalgogeeks%2bunsubscr...@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 algoge...@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.comalgogeeks%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en. -- What are we to be? -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.comalgogeeks%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in email%3adipan...@iitr.ernet.in -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@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] 10 Most Frequent Search Text
hey... what's about the storage managment ? the search text may not be a fixed length string.. is implementation of a node is fessible? one alternative solution may be associate a hash table along with this. but again the problem with collision ,, to avoid collision u can use perfect hashing with universal hash function. you can also use an alternative solution hash function and priority queue using MAX heap... On Mon, Dec 27, 2010 at 2:20 AM, Chi i...@chihoang.de wrote: A trie is a binary tree with it nodes has as many leafs as is suitable. A binary tree has only 2 leafs per nodes. In a trie it happens that a node doesn't contain any leafs. This happens over many nodes. This is considerable a waste of space. A radix-trie tries to eliminate this empty nodes by compressing them into 1 node. The difference between a radix-trie and suffix-trie is that a suffix-trie can solve text-based problems. A radix-trie is good to store a dictionnary and search for words. Or associative arrays. Or ip addresses. Unlike balanced trees, radix trees permit lookup, insertion, and deletion in O(k) time rather than O(log n). This doesn't seem like an advantage, since normally k ≥ log n, but in a balanced tree every comparison is a string comparison requiring O(k) worst-case time, many of which are slow in practice due to long common prefixes. In a trie, all comparisons require constant time, but it takes m comparisons to look up a string of length m. Radix trees can perform these operations with fewer comparisons and require many fewer nodes. K=key n=string I have a written a kart-trie in php: https://sourceforge.net/projects/kart-trie The only difference to a radix-trie is that the decision to branch either left or right is used with a key of 32-bit. - Ursprüngliche Mitteilung - @Chi: Would you please explain the process in a little bit more details? It will be helpful. Is Trie and Radix-Trie same? -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@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 algoge...@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.comalgogeeks%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in email%3adipan...@iitr.ernet.in -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@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] Google Technical Round
refer careercup.com On 12/18/10, jaladhi dave jaladhi.k.d...@gmail.com wrote: Can you give an example, to clarify certain points. -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in email%3adipan...@iitr.ernet.in -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@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 interview question
see careercup.com On Sat, Dec 18, 2010 at 1:49 AM, anujbhambhani anuj.bhambh...@gmail.comwrote: write a recursive function to convert a BST into sorted doubly linked list. -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.comalgogeeks%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 Lab: 286454 email:dipan...@iitr.ernet.in email%3adipan...@iitr.ernet.in -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@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: switch vs if -- which is faster
both are same .. because any good optimizing compiler generate same assembly code of them... On Mon, Nov 22, 2010 at 9:38 AM, Gene gene.ress...@gmail.com wrote: A good compiler will never generate a switch that is slower than an if...else chain. They will analyze the switch cases and pick one of several options for code generation. These may include cascaded conditional jumps (like if...else code), simple jump tables, segmented jump tables (cascaded jumps pick one of several jump tables because a single table would be too big), binary searches in a sorted table of case values, and perfect hash functions. These are the ones I've seen. There may be others. On Nov 21, 8:15 am, shiva shivanand.kadwad...@gmail.com wrote: As per my understanding it is compiler depending thing.. what i feel is switch need to evaluate the expression only once but if else if need to evaluate the expression more than once(what if expression stored in variable and then compare...) Does any one please comment difference in speed of switch and if depending on how it is implemented... I heard switch uses jump table for its operation. -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.comalgogeeks%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 email:dipan...@iitr.ernet.in email%3adipan...@iitr.ernet.in -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@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: Swap the LSB and MSB within themself of given no.
x=((x3)(0x11)|(a3) 0x88 |(a1) 0x44 | (a1) 0x22) On Sun, Nov 21, 2010 at 11:11 PM, Dave dave_and_da...@juno.com wrote: @Coolfrog$: Don't forget the bitwise logical products. What is the bit patterns in those hexadecimal constants? Work out the whole example and you will see how it works. -- Dave On Nov 21, 8:21 am, coolfrog$ dixit.coolfrog.div...@gmail.com wrote: @gene plz explain .. what is going on... by taking example. i am unable to run a test case 1. x=0xAD (1010 1101) 2. x1 ===01011010 | x1 01010110 x =0100 how we will get answer as ( 0101 1011).?? On Sun, Nov 21, 2010 at 9:59 AM, Gene gene.ress...@gmail.com wrote: if the input is in unsigned char x, then x = ((x 1) 0xAA) | ((x 1) 0x55) x = ((x 2) 0xCC) | ((x 2) 0x33) On Nov 20, 10:41 pm, Divesh Dixit dixit.coolfrog.div...@gmail.com wrote: assuming all are 8bit no. input = 0x46 (0100 0110) output = 0x26 ( 0010 0110 ) input = 0x75 (0111 0101) output = 0xFC (1110 1010 ) Algorithm..??? -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.comalgogeeks%2bunsubscr...@googlegroups.com algogeeks%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en. -- *Divesh* (¨`·.·´¨) Always `·.¸(¨`·.·´¨ ) Keep (¨`·.·´¨)¸.·´Smiling! `·.¸.·´ Life can give u 100's of reason 2cry,but u can give life 1000's of reasons 2Smile- 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 algoge...@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.comalgogeeks%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 email:dipan...@iitr.ernet.in email%3adipan...@iitr.ernet.in -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@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: plz explain output
printf is very week to convert int to float or vice versa.. please read D. Ritchie for details. On 10/9/10, @shu ashu.nit...@gmail.com wrote: On Oct 9, 11:51 am, Ashutosh Tripathi ashu.nit...@gmail.com wrote: hey! i am also unable to explain but one thing i got if we use %d in place of %f,we will get the correct output. we must use %d as x is of int data type.so the code is itself wrong. or u can change x to float data type..which means u have to modify the code -- Ashutosh Tripathi UG Student Computer Science and Engineering Department, Nit Durgapur,West Bengal. -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@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. -- DIPANKAR DUTTA M-TECH,Computer Science Engg. EC Dept,IIT ROORKEE Uttarakhand , India – 247667 --- website:http://people.iitr.ernet.in/shp/09535009/Website/index.html ph no-09045809987 email:dipan...@iitr.ernet.in email%3adipan...@iitr.ernet.in -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algoge...@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.