[algogeeks] Re: spoj problem EASYMATH
thanx :) -- 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/-/iy_uho_bmMYJ. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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: spoj problem EASYMATH
an idea of the approach would be enough.. plz help.. -- 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/-/3H3O2K4KBBMJ. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] spoj problem EASYMATH
an idea of the approach would be enough.. plz 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] spoj problem EASYMATH
help needed in spoj problem EASYMATH http://spoj.pl/problems/EASYMATH.. i thought about inclusion exclusion principle but unable to get to a solution.. plz help.. -- 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/-/Zm2bwN2FHRQJ. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] plz explain output y it is 1212
Hi..please repost your code after properly formatting ...it is not readable...and throws compilation errors. -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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: Interview Question
@sahil Can you please explain your question with an example ? -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] Codeforces Problem
[image: Inline image 1] If u look at the pattern closely...and count the number of tiles vertically from left...the pattern followed is 2,3,4,4,3,2 and 2+3+4+4+3+2=18 so for any a,b,c...u will need an array of size A[b+c-1] now start populating the array from start and end simultaneously and increment the value by 1 after each iteration till u reach the maximum allowed value ,i,e (a+b-1) which is (2+3-1) =4 in above case...now populate rest of the array with (a+b-1) so, for a=2,b=3,c=4; (b+c-1)=6; (a+b-1)=4; A[6]=[2,3,4,4,3,2] summing up gives 18 I think this should give u the correct output...please let me know if i am wrong here. -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en. image.png
Re: [algogeeks] Codeforces Problem
@aman +1 -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] spoj problem
plz nyone explain how to approach this problem.. http://www.spoj.pl/problems/XORROUND/ -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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: Inplace Array Convertion
@shiva...keep swapping the underline elements a1*a2*a3a4a5*b1*b2b3b4b5c1c2c3c4c5 a1b1*a3*a4a5a2b2b3b4b5*c1*c2c3c4c5 a1b1c1*a4*a5*a2*b2b3b4b5a3c2c3c4c5 a1b1c1a2*a5*a4*b2*b3b4b5a3c2c3c4c5 a1b1c1a2b2*a4*a5b3b4b5a3*c2*c3c4c5 a1b1c1a2b2c2*a5*b3b4b5*a3*a4c3c4c5 a1b1c1a2b2c2a3b3*b4*b5a5a4*c3*c4c5 a1b1c1a2b2c2a3b3c3*b5*a5*a4*b4c4c5 a1b1c1a2b2c2a3b3c3a4*a5*b5*b4*c4c5 a1b1c1a2b2c2a3b3c3a4b4*b5*a5*c4*c5 a1b1c1a2b2c2a3b3c3a4b4*c4*a5*b5*c5 a1b1c1a2b2c2a3b3c3a4b4c4a5b5c5 -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] explain the output please.....
@raghav garg...run the code and see the output,the output comes fail1pass2 -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] explain the output please.....
* im using devc compiler * when if(ci) is encountered since integer has higher precedence over char ,so char is type casted to int so, (ci) is equivalent to (-64-32) which is false ,so fail1 is printed, -16 is converted to 4,294,967,295 - 16=4,294,967,280(so it is unsigned now) for(iu) integer i is converted to unsigned int so (unsigned int)i=4,294,967,264 so(iu)==(4,294,967,2644,294,967,280) is true so output is pass2 http://stackoverflow.com/questions/5563000/implicit-type-conversion-rules-in-c-operators http://h30097.www3.hp.com/docs/base_doc/DOCUMENTATION/V40F_HTML/AQTLTBTE/DOCU_067.HTM (plz correct me if im 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.
Re: [algogeeks] explain the output please.....
hey raghav my turbo c compiler gives output fail1pass2 -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] money matters
can u plz expain imnewcoder's approach with an example...? -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] can somebody kindly explain what would be the output for the following program
output= b try running on turbo c . -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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
which college? -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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: rise and fall of power
I am using following statements to print the first... scanf(%lf%lf,n,k); double v = n*log10(n); double dummy; double ff = modf(v,dummy); double val = floor(pow(10.0,ff+k-1)); printf(%.0f,val); this code works fine when for big values of n like n=234232 , k=9 i get value=943982129 but for even bigger numbers like n=457474575 ,k=9 i get value =278661176 which is not correct,i should get value=278660968 how to make above code produce more precise results... -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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: rise and fall of power
nk 34 9: 117566389 23 8: 20880467 92 9: 466101087 1997: 2963208 234232 9: 943982129 3476566 9: 226270832 56999 9: 349261536 9 9: 367879441 567891234 9: 191465113 457474575 9: 278660968 (got these from the comments section.) -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] codechef mixtures problem
the above question is similar to matrix-chain multiplication on page number -370,dynamic programming chapter,Introduction to Algorithms,t h cormen,leiserson,rivest,stein -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] New Group For Practicing and Learning Efficient Ways of Coding
I think once the questions are posted more peolpe will join 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] rise and fall of power
since 1 ≤ *n* ≤ 109 so for n=10^9 you would need an array of size (10^9)^(10^9) which is not possible.. so your approach wont 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.
Re: [algogeeks] Amdocs
I cracked amdocs interview...u need to stress on following topics.. *ONLINE TEST* 1)UNIX Questions on various commands.Important ones are ls,tr,head,tail,tee,gzip and questions on bash script. 2)SQL Questions on access levels for diff. users,outer join,inner join,left and right join,ddl and dml commands(like delete,truncate,etc) 3)C/C++/Java I choose C...questions were based on finding outputs mainly on pointers,switch,1 question was also about unions. 4)Basic aptitude questions 5)Learning ability A paragraph will be given to you,based on that 3-4 questions were asked.You will have enough time to read to read and answer. *INTERVIEW* *TECHNICAL* 1)C language(pointers mainly) or any other language u choose mainly from c/c++/java. 2)sql(various dml and ddl commands) 3)data strucures 4)basic knowlegde of automata theory(including its mathematical representations) *HR* Just introduce yourself nicely and also him questions when needed to pretend that u are really interested in joining and are flexible with the location and working hours. So ,that's it.Best of Luck !!! -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] Give the logic for it
let arr1[5]={6,7,8,9,10} arr2[5]={1,2,3,4,8} your codes gives answer=5 which is not correct... the correct answer should be=6.5 but since you are returning integer and answer would be=6 -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] Amdocs
my number= +919939569122 gtalk id=gauravyadav1...@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] structure padding
@rahul sharma struct a { int a; float b; char c; }b; printf(%d,sizeof(b)); when u declare a struct variable (b in this case)...4 bytes are used for int a,4 for float b and similarly 4 bytes for char c(though only 1 byte is actually used). but now look at following code.. struct a { double a; float b; char c; }b; printf(%d,sizeof(b)); in this case u get the output 16 and not 24...because 8 bytes are used for double a,and in next 8 bytes 4 bytes are used for float b and char c each. -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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 os ques on pipelining
bharatkumar bagan...can u plz explain why u multipiled (160+5) with 999 ? -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from 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] output expalnation?
b=6 will not execute.. -- You received this message because you are subscribed to the Google Groups Algorithm Geeks group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.