Re: [algogeeks] plzzzzzzzz heeeppppp!!!!!!!!!!1

2011-09-14 Thread Prem Krishna Chettri
Its an open ended question for the New Guys..
 So.. here its some analysis..
   If its project is R&D with high profile org like Amazon.. Google.. SDET
is Developer in Test  (Framework Developer for TESTING) but QA is a Complete
Tester (Mostly No Code Work).. So SDET will develop in basically in Some
Scripting Languages like Ruby.. Python .. Shell etc..
   However Development is not only writing feature in Complied Languages
like C/C++ and Java but also maintenance and bug Fix..


  So, for High profile org.. its always a great wk Exp in any of these filed
. but for medium org its always Dev on top (few Exception)..

Now its your Choice.


Prem

On Thu, Sep 15, 2011 at 12:10 PM, siddharam suresh
wrote:

> testing is very broad area of s/w development.
> first get clear about the job,
>
> when i was giving interview with MS for SDET, they said its developing test
> s/w for already build s/w.   my view, testing requires more skills than
> developer, to find out the flaws in the code.
>
> Thank you,
> Sid.
>
>
>
> On Thu, Sep 15, 2011 at 11:42 AM, vivek goel 
> wrote:
>
>> hello  nikhil,
>>
>>suppose if we currently opt  for testing OR consultant
>>  profile
>>
>> then  Is it possible to switch to Software Development profile   later
>> on.
>> plss tell me...
>>
>> On 9/15/11, Nikhil Kumar  wrote:
>> > Testing profile : You have to test the features developed by
>> others.Kinda
>> > bruteforce work , you will be given a set of commands and a large no. of
>> > test cases.All you have to do is run commands and validate test cases
>> again
>> > and again.Boring.Only periodic growth.
>> >
>> > Developers: Much better. You have to develop new features yourself.You
>> will
>> > apply concepts to mould the product.Growth chances are good.Growth basis
>> is
>> > your talent and capability.
>> >
>> >
>> >
>> > On Thu, Sep 15, 2011 at 11:07 AM, abhinav gupta
>> > wrote:
>> >
>> >> in my opinion developer profile is better than testing...one
>> >>
>> >>
>> >> On Thu, Sep 15, 2011 at 10:57 AM, rahul sharma
>> >> wrote:
>> >>
>> >>> hey guys plz tell the difference b/w testing n develp.  profile ??? n
>> >>> joing i n testing profile has growth as much as in develpoer???plz
>> >>> tell soon..?should i go in testing profile in lagre industry or in
>> >>> developer in medium scale...plz hepl
>> >>>
>> >>> --
>> >>> You received this message because you are subscribed to the Google
>> Groups
>> >>> "Algorithm Geeks" group.
>> >>> To post to this group, send email to algogeeks@googlegroups.com.
>> >>> To unsubscribe from 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.
>> >>
>> >
>> >
>> >
>> > --
>> > Nikhil Kumar , Software Engineer @ Ciena Gurgaon.
>> > B.E.( Information Technology ) ,
>> > NSIT Delhi , 2007-2011
>> >
>> > --
>> > You received this message because you are subscribed to the Google
>> Groups
>> > "Algorithm Geeks" group.
>> > To post to this group, send email to algogeeks@googlegroups.com.
>> > To unsubscribe from this group, send email to
>> > algogeeks+unsubscr...@googlegroups.com.
>> > For more options, visit this group at
>> > http://groups.google.com/group/algogeeks?hl=en.
>> >
>> >
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks] plzzzzzzzz heeeppppp!!!!!!!!!!1

2011-09-14 Thread siddharam suresh
testing is very broad area of s/w development.
first get clear about the job,

when i was giving interview with MS for SDET, they said its developing test
s/w for already build s/w.   my view, testing requires more skills than
developer, to find out the flaws in the code.

Thank you,
Sid.



On Thu, Sep 15, 2011 at 11:42 AM, vivek goel wrote:

> hello  nikhil,
>
>suppose if we currently opt  for testing OR consultant
>  profile
>
> then  Is it possible to switch to Software Development profile   later
> on.
> plss tell me...
>
> On 9/15/11, Nikhil Kumar  wrote:
> > Testing profile : You have to test the features developed by others.Kinda
> > bruteforce work , you will be given a set of commands and a large no. of
> > test cases.All you have to do is run commands and validate test cases
> again
> > and again.Boring.Only periodic growth.
> >
> > Developers: Much better. You have to develop new features yourself.You
> will
> > apply concepts to mould the product.Growth chances are good.Growth basis
> is
> > your talent and capability.
> >
> >
> >
> > On Thu, Sep 15, 2011 at 11:07 AM, abhinav gupta
> > wrote:
> >
> >> in my opinion developer profile is better than testing...one
> >>
> >>
> >> On Thu, Sep 15, 2011 at 10:57 AM, rahul sharma
> >> wrote:
> >>
> >>> hey guys plz tell the difference b/w testing n develp.  profile ??? n
> >>> joing i n testing profile has growth as much as in develpoer???plz
> >>> tell soon..?should i go in testing profile in lagre industry or in
> >>> developer in medium scale...plz hepl
> >>>
> >>> --
> >>> You received this message because you are subscribed to the Google
> Groups
> >>> "Algorithm Geeks" group.
> >>> To post to this group, send email to algogeeks@googlegroups.com.
> >>> To unsubscribe from 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.
> >>
> >
> >
> >
> > --
> > Nikhil Kumar , Software Engineer @ Ciena Gurgaon.
> > B.E.( Information Technology ) ,
> > NSIT Delhi , 2007-2011
> >
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Algorithm Geeks" group.
> > To post to this group, send email to algogeeks@googlegroups.com.
> > To unsubscribe from this group, send email to
> > algogeeks+unsubscr...@googlegroups.com.
> > For more options, visit this group at
> > http://groups.google.com/group/algogeeks?hl=en.
> >
> >
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

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



Re: [algogeeks] program

2011-09-14 Thread sagar pareek
Use hashing like counting sort...

On Wed, Sep 14, 2011 at 11:20 AM, raj  wrote:

> program to find the top 3 repeating number from the given array
> eg
> You r given an array and u have to find out the top 3 repeated
> numbers.
>  for ex: GAURAV[]={20,8,3,7,8,9,20,6,4,6,20,8,20}
> so the output will be: 20 is repeated 4 times 8 is repeated 3 times 6
> is repeated 2 times.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>


-- 
**Regards
SAGAR PAREEK
COMPUTER SCIENCE AND ENGINEERING
NIT ALLAHABAD

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



Re: [algogeeks] plzzzzzzzz heeeppppp!!!!!!!!!!1

2011-09-14 Thread vivek goel
hello  nikhil,

suppose if we currently opt  for testing OR consultant  profile

then  Is it possible to switch to Software Development profile   later
on.
plss tell me...

On 9/15/11, Nikhil Kumar  wrote:
> Testing profile : You have to test the features developed by others.Kinda
> bruteforce work , you will be given a set of commands and a large no. of
> test cases.All you have to do is run commands and validate test cases again
> and again.Boring.Only periodic growth.
>
> Developers: Much better. You have to develop new features yourself.You will
> apply concepts to mould the product.Growth chances are good.Growth basis is
> your talent and capability.
>
>
>
> On Thu, Sep 15, 2011 at 11:07 AM, abhinav gupta
> wrote:
>
>> in my opinion developer profile is better than testing...one
>>
>>
>> On Thu, Sep 15, 2011 at 10:57 AM, rahul sharma
>> wrote:
>>
>>> hey guys plz tell the difference b/w testing n develp.  profile ??? n
>>> joing i n testing profile has growth as much as in develpoer???plz
>>> tell soon..?should i go in testing profile in lagre industry or in
>>> developer in medium scale...plz hepl
>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups
>>> "Algorithm Geeks" group.
>>> To post to this group, send email to algogeeks@googlegroups.com.
>>> To unsubscribe from 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.
>>
>
>
>
> --
> Nikhil Kumar , Software Engineer @ Ciena Gurgaon.
> B.E.( Information Technology ) ,
> NSIT Delhi , 2007-2011
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

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



Re: [algogeeks] plzzzzzzzz heeeppppp!!!!!!!!!!1

2011-09-14 Thread Nikhil Kumar
Testing profile : You have to test the features developed by others.Kinda
bruteforce work , you will be given a set of commands and a large no. of
test cases.All you have to do is run commands and validate test cases again
and again.Boring.Only periodic growth.

Developers: Much better. You have to develop new features yourself.You will
apply concepts to mould the product.Growth chances are good.Growth basis is
your talent and capability.



On Thu, Sep 15, 2011 at 11:07 AM, abhinav gupta wrote:

> in my opinion developer profile is better than testing...one
>
>
> On Thu, Sep 15, 2011 at 10:57 AM, rahul sharma wrote:
>
>> hey guys plz tell the difference b/w testing n develp.  profile ??? n
>> joing i n testing profile has growth as much as in develpoer???plz
>> tell soon..?should i go in testing profile in lagre industry or in
>> developer in medium scale...plz hepl
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from 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.
>



-- 
Nikhil Kumar , Software Engineer @ Ciena Gurgaon.
B.E.( Information Technology ) ,
NSIT Delhi , 2007-2011

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



Re: [algogeeks]

2011-09-14 Thread UTKARSH SRIVASTAV
@rahul and @suarabh the program is giving different output on ubuntu and
redhat.. is ubuntu and redhat deals shell
differently

On Thu, Sep 15, 2011 at 9:45 AM, rahul vatsa  wrote:

> @utkarsh, its opensuse.
>
> @saurabh, i agree wht u r saying i hd also checkd that in man page. nd hd
> tried @terminal with sh, and it hadn't expanded. bt wen i run this prog on
> my m/c, it gives the expanded output.
>
>
> linux-7ap5:/home/user/test # ls
> system.c
> linux-7ap5:/home/user/test # cat system.c
> #include 
>
> main()
> {
>  system("echo {a,b,c}{a,b,c}{a,b,c} ");
> }
> linux-7ap5:/home/user/test # make system
> cc system.c   -o system
> linux-7ap5:/home/user/test # ./system
> aaa aab aac aba abb abc aca acb acc baa bab bac bba bbb bbc bca bcb bcc caa
> cab cac cba cbb cbc cca ccb ccc
> linux-7ap5:/home/user/test #
>
>
>
> On Wed, Sep 14, 2011 at 10:54 PM, saurabh singh wrote:
>
>> If you go a bit deeper into the system calls that system makes you will
>> realize that the argument is actually expanded as "sh -c echo
>> {abc}{abc}{abc}
>> The expansion facility is provided by bash but not sh.(You may verify my
>> claim)
>> The default shell is bash.*switch to sh mode and you will realize whats
>> happening.*
>>
>>
>> On Thu, Sep 15, 2011 at 2:43 AM, UTKARSH SRIVASTAV <
>> usrivastav...@gmail.com> wrote:
>>
>>> @rahul have you tried it n your system and if yes then which os?
>>>
>>>
>>> On Thu, Sep 15, 2011 at 2:28 AM, UTKARSH SRIVASTAV <
>>> usrivastav...@gmail.com> wrote:
>>>
 yes it's giving wrong output on terminal using gcc compiler in ubuntu


 On Thu, Sep 15, 2011 at 1:25 AM, Amol Sharma wrote:

> though it is giving the expected output on the ideone but i am not
> getting the the output on the terminal using gcc compiler it is just
> printing {a,b,c}{a,b,c}{a,b,c} what could be the reason ?
>
> my OS- Ubuntu 10.04
> @rahul what's ur os ?
>
> --
>
>
> Amol Sharma
> Third Year Student
> Computer Science and Engineering
> MNNIT Allahabad
>   
> 
>
>
>
>
>
> On Thu, Sep 15, 2011 at 1:20 AM, Amol Sharma 
> wrote:
>
>> http://ideone.com/WQxfK
>> --
>>
>>
>> Amol Sharma
>> Third Year Student
>> Computer Science and Engineering
>> MNNIT Allahabad
>>   
>> 
>>
>>
>>
>>
>>
>> On Thu, Sep 15, 2011 at 1:13 AM, rahul vatsa 
>> wrote:
>>
>>> i tried ur code & it gives the same output as wen u execute the
>>> command on terminal.
>>>
>>>
>>> On Wed, Sep 14, 2011 at 3:03 PM, UTKARSH SRIVASTAV <
>>> usrivastav...@gmail.com> wrote:
>>>

 if i write on terminal echo {a,b,c}{a,b,c}{a,b,c} then i get the
 output all possible combination of a,b,c and if i write like this

 main()
 {
  system("echo {a,b,c}{a,b,c}{a,b,c} ");
 }
 output : {a,b,c}{a,b,c}{a,b,c}
 why?
 in system command whatever we write is taken like a command


 --
 *UTKARSH SRIVASTAV
 CSE-3
 B-Tech 3rd Year
 @MNNIT ALLAHABAD*


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

>>>
>>>  --
>>> You received this message because you are subscribed to the Google
>>> Groups "Algorithm Geeks" group.
>>> To post to this group, send email to algogeeks@googlegroups.com.
>>> To unsubscribe from 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.
>



 --
 *UTKARSH SRIVASTAV
 CSE-3
 B-Tech 3rd Year
 @MNNIT ALLAHABAD*



>>>
>>>
>>> --
>>> *UTKARSH SRIVASTAV
>>> CSE-3
>>> B-Tech 3rd Year
>>> @MNNIT ALLAHA

Re: [algogeeks] plzzzzzzzz heeeppppp!!!!!!!!!!1

2011-09-14 Thread abhinav gupta
in my opinion developer profile is better than testing...one

On Thu, Sep 15, 2011 at 10:57 AM, rahul sharma wrote:

> hey guys plz tell the difference b/w testing n develp.  profile ??? n
> joing i n testing profile has growth as much as in develpoer???plz
> tell soon..?should i go in testing profile in lagre industry or in
> developer in medium scale...plz hepl
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

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



Re: [algogeeks] Math Puzzle

2011-09-14 Thread Tamanna Afroze
P+Q = -R
(P+Q)3 = -R3
P3+Q3+3PQ(P+Q) = -R3
P3+Q3+R3 = =3PQ(P+Q)
P3+Q3+R3 = 3PQR

NOW,
P2/QR+Q2/PR+R2/PQ=(P3+Q3+R3)PQR = 3

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] Math Puzzle

2011-09-14 Thread Terence

   P^2/QR+Q^2/PR+R^2/PQ
 = (P^3+Q^3+R^3)/PQR
 = ((P+Q+R)(P^2+Q^2+R^2-PQ-QR-PR)+3PQR)/PQR
 = 3

On 2011-9-15 13:29, rahul sharma wrote:

hw?

On Thu, Sep 15, 2011 at 10:57 AM, Tamanna Afroze > wrote:


yah the ans is 3

-- 
You received this message because you are subscribed to the Google

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


--
You received this message because you are subscribed to the Google 
Groups "Algorithm Geeks" group.

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


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



Re: [algogeeks] Math Puzzle

2011-09-14 Thread rahul sharma
hw?

On Thu, Sep 15, 2011 at 10:57 AM, Tamanna Afroze wrote:

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

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



Re: [algogeeks] Math Puzzle

2011-09-14 Thread Tamanna Afroze
yah the ans is 3

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] plzzzzzzzz heeeppppp!!!!!!!!!!1

2011-09-14 Thread rahul sharma
hey guys plz tell the difference b/w testing n develp.  profile ??? n
joing i n testing profile has growth as much as in develpoer???plz
tell soon..?should i go in testing profile in lagre industry or in
developer in medium scale...plz hepl

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: branching factor when BFS and DFS of a graph is same

2011-09-14 Thread abhinav gupta
@siddharam:

i think the above example is isomorphic
because in isomopic we check for the degree of each node in one tree to the
corresponding degree of another tree is present or not .

like eg:-

p-q--r---s

is isomorphic with


a--b--c---d




On Thu, Sep 15, 2011 at 10:15 AM, siddharam suresh
wrote:

> as per your example
>
>  preorder  inorder
> tree1: ab  ba
> tree2: ab  ab
>
> both are not isomorphic.
>
> its easy to extend preorder/DFS to
> replace two calls to children with for loop considering the graph is
> N-array tree.
>
>
>
> Thank you,
> Sid.
>
>
>
> On Wed, Sep 14, 2011 at 5:50 PM, bugaboo  wrote:
>
>> @siddharam:
>>
>> Performing inorder and pre/postorder will still have false positives.
>>
>> Consider 2 trees one with root node "a" with node "b" as left child,
>> another tree with root node "a" with node "b" as its right child.
>>
>> Anyway, for binary trees, I am aware of a recursive solution to find
>> out similarity or isomorphism. Not sure how this extends for a graph.
>> Always thought a DFS and/or BFS should suffice but apparently not.
>>
>> On Sep 14, 1:43 am, siddharam suresh  wrote:
>> > bharath.sriram,
>> > perform inorder traversal and peorder/postorder traversal on both tree
>> then
>> > compare both the result of two tree.
>> > Thank you,
>> > Sid.
>> >
>> >
>> >
>> >
>> >
>> >
>> >
>> > On Wed, Sep 14, 2011 at 10:22 AM, bugaboo 
>> wrote:
>> > > This brings up another interesting question. How do you find out if 2
>> > > graphs are identical? (By identical, I mean exact similarity and NOT
>> > > isomorphism). Clearly, checking to see if both the DFS traversal and
>> > > BFS traversal match seem to have false positives as Bharathkumar
>> > > mentioned.
>> >
>> > > On Sep 13, 12:50 am, bharatkumar bagana > >
>> > > wrote:
>> > > > @nishaanth:
>> > > > ex:
>> > > >1
>> > > > 23
>> > > >  4
>> > > > 5
>> > > > bfs:12345
>> > > > dfs:12345
>> > > > branching factor of this tree  is not 1 ..
>> >
>> > > > On Tue, Sep 13, 2011 at 9:38 AM, nishaanth 
>> > > wrote:
>> > > > > yes branching factor should be 1. it can be not equal to 1 only
>> for the
>> > > > > penultimate node. by penultimate node i mean whose children are
>> the
>> > > leaves
>> > > > > of the tree. rest all cases it should be 1.
>> >
>> > > > > On Tue, Sep 13, 2011 at 9:24 AM, siddharam suresh <
>> > > siddharam@gmail.com
>> > > > > > wrote:
>> >
>> > > > >> cant say if there more than one leaf element
>> > > > >> still both the algo give same result
>> > > > >> Thank you,
>> > > > >> Sid.
>> >
>> > > > >> On Tue, Sep 13, 2011 at 7:52 AM, Sundi 
>> wrote:
>> >
>> > > > >>> if the dfs and bfs of a graph is same, does it mean that if the
>> > > > >>> branching factor of a graph is one?
>> >
>> > > > >>> a>b>c>d
>> >
>> > > > >>> example: both dfs abd bfs are same 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.
>> >
>> > > > >>  --
>> > > > >> You received this message because you are subscribed to the
>> Google
>> > > Groups
>> > > > >> "Algorithm Geeks" group.
>> > > > >> To post to this group, send email to algogeeks@googlegroups.com.
>> > > > >> To unsubscribe from this group, send email to
>> > > > >> algogeeks+unsubscr...@googlegroups.com.
>> > > > >> For more options, visit this group at
>> > > > >>http://groups.google.com/group/algogeeks?hl=en.
>> >
>> > > > > --
>> > > > > S.Nishaanth,
>> > > > > Computer Science and engineering,
>> > > > > IIT Madras.
>> >
>> > > > > --
>> > > > > You received this message because you are subscribed to the Google
>> > > Groups
>> > > > > "Algorithm Geeks" group.
>> > > > > To post to this group, send email to algogeeks@googlegroups.com.
>> > > > > To unsubscribe from this group, send email to
>> > > > > algogeeks+unsubscr...@googlegroups.com.
>> > > > > For more options, visit this group at
>> > > > >http://groups.google.com/group/algogeeks?hl=en.
>> >
>> > > > --
>> >
>> > > > **Please do not print this e-mail until urgent requirement. Go
>> Green!!
>> > > > Save Papers <=> Save Trees
>> > > > *BharatKumar Bagana*
>> > > > **http://www.google.com/profiles/bagana.bharatkumar<
>> > >http://www.google.com/profiles/bagana.bharatkumar>
>> > > > *
>> > > > Mobile +91 8056127652*
>> > > > 
>> >
>> > > --
>> > > You received this message because you are subscribed to the Google
>> Groups
>> > > "Algorithm Geeks" group.
>> > > To post to this group, send email to algogeeks@googlegroups.com.
>> > > To unsubscribe from this group, send email to
>> > > algogeeks+unsubsc

Re: [algogeeks] OS

2011-09-14 Thread mohan kumar
http://www.tenouk.com/WinVirtualAddressSpace.html

go to this link.
think it will help you...
i

On Wed, Sep 14, 2011 at 7:48 PM, teja bala wrote:

> can any one tell the difference between  ADDRESS SPACE and VIRTUAL
> ADDRESS SPACE?
>
> thx in advance.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>


-- 

   - *MOHAN KUMAR*

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] Math Puzzle

2011-09-14 Thread jestincobol nair
ans is 3 :)


On Thu, Sep 15, 2011 at 10:35 AM, jestincobol nair wrote:

> wat is p2 p's square??
>
>
> On Thu, Sep 15, 2011 at 10:26 AM, NAGARAJAN SIVARAMAN 
> wrote:
>
>> if P+Q+R= 0  then P2 /QR  + Q2/PR + R2/PQ = ??
>>
>> how to solve this??
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>>
>

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



Re: [algogeeks] Math Puzzle

2011-09-14 Thread jestincobol nair
wat is p2 p's square??

On Thu, Sep 15, 2011 at 10:26 AM, NAGARAJAN SIVARAMAN wrote:

> if P+Q+R= 0  then P2 /QR  + Q2/PR + R2/PQ = ??
>
> how to solve this??
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

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



[algogeeks] Math Puzzle

2011-09-14 Thread NAGARAJAN SIVARAMAN
if P+Q+R= 0  then P2 /QR  + Q2/PR + R2/PQ = ??

how to solve this??

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: branching factor when BFS and DFS of a graph is same

2011-09-14 Thread siddharam suresh
as per your example

 preorder  inorder
tree1: ab  ba
tree2: ab  ab

both are not isomorphic.

its easy to extend preorder/DFS to
replace two calls to children with for loop considering the graph is N-array
tree.



Thank you,
Sid.



On Wed, Sep 14, 2011 at 5:50 PM, bugaboo  wrote:

> @siddharam:
>
> Performing inorder and pre/postorder will still have false positives.
>
> Consider 2 trees one with root node "a" with node "b" as left child,
> another tree with root node "a" with node "b" as its right child.
>
> Anyway, for binary trees, I am aware of a recursive solution to find
> out similarity or isomorphism. Not sure how this extends for a graph.
> Always thought a DFS and/or BFS should suffice but apparently not.
>
> On Sep 14, 1:43 am, siddharam suresh  wrote:
> > bharath.sriram,
> > perform inorder traversal and peorder/postorder traversal on both tree
> then
> > compare both the result of two tree.
> > Thank you,
> > Sid.
> >
> >
> >
> >
> >
> >
> >
> > On Wed, Sep 14, 2011 at 10:22 AM, bugaboo 
> wrote:
> > > This brings up another interesting question. How do you find out if 2
> > > graphs are identical? (By identical, I mean exact similarity and NOT
> > > isomorphism). Clearly, checking to see if both the DFS traversal and
> > > BFS traversal match seem to have false positives as Bharathkumar
> > > mentioned.
> >
> > > On Sep 13, 12:50 am, bharatkumar bagana 
> > > wrote:
> > > > @nishaanth:
> > > > ex:
> > > >1
> > > > 23
> > > >  4
> > > > 5
> > > > bfs:12345
> > > > dfs:12345
> > > > branching factor of this tree  is not 1 ..
> >
> > > > On Tue, Sep 13, 2011 at 9:38 AM, nishaanth 
> > > wrote:
> > > > > yes branching factor should be 1. it can be not equal to 1 only for
> the
> > > > > penultimate node. by penultimate node i mean whose children are the
> > > leaves
> > > > > of the tree. rest all cases it should be 1.
> >
> > > > > On Tue, Sep 13, 2011 at 9:24 AM, siddharam suresh <
> > > siddharam@gmail.com
> > > > > > wrote:
> >
> > > > >> cant say if there more than one leaf element
> > > > >> still both the algo give same result
> > > > >> Thank you,
> > > > >> Sid.
> >
> > > > >> On Tue, Sep 13, 2011 at 7:52 AM, Sundi 
> wrote:
> >
> > > > >>> if the dfs and bfs of a graph is same, does it mean that if the
> > > > >>> branching factor of a graph is one?
> >
> > > > >>> a>b>c>d
> >
> > > > >>> example: both dfs abd bfs are same 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.
> >
> > > > >>  --
> > > > >> You received this message because you are subscribed to the Google
> > > Groups
> > > > >> "Algorithm Geeks" group.
> > > > >> To post to this group, send email to algogeeks@googlegroups.com.
> > > > >> To unsubscribe from this group, send email to
> > > > >> algogeeks+unsubscr...@googlegroups.com.
> > > > >> For more options, visit this group at
> > > > >>http://groups.google.com/group/algogeeks?hl=en.
> >
> > > > > --
> > > > > S.Nishaanth,
> > > > > Computer Science and engineering,
> > > > > IIT Madras.
> >
> > > > > --
> > > > > You received this message because you are subscribed to the Google
> > > Groups
> > > > > "Algorithm Geeks" group.
> > > > > To post to this group, send email to algogeeks@googlegroups.com.
> > > > > To unsubscribe from this group, send email to
> > > > > algogeeks+unsubscr...@googlegroups.com.
> > > > > For more options, visit this group at
> > > > >http://groups.google.com/group/algogeeks?hl=en.
> >
> > > > --
> >
> > > > **Please do not print this e-mail until urgent requirement. Go
> Green!!
> > > > Save Papers <=> Save Trees
> > > > *BharatKumar Bagana*
> > > > **http://www.google.com/profiles/bagana.bharatkumar<
> > >http://www.google.com/profiles/bagana.bharatkumar>
> > > > *
> > > > Mobile +91 8056127652*
> > > > 
> >
> > > --
> > > You received this message because you are subscribed to the Google
> Groups
> > > "Algorithm Geeks" group.
> > > To post to this group, send email to algogeeks@googlegroups.com.
> > > To unsubscribe from 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 becaus

Re: [algogeeks]

2011-09-14 Thread rahul vatsa
@utkarsh, its opensuse.

@saurabh, i agree wht u r saying i hd also checkd that in man page. nd hd
tried @terminal with sh, and it hadn't expanded. bt wen i run this prog on
my m/c, it gives the expanded output.


linux-7ap5:/home/user/test # ls
system.c
linux-7ap5:/home/user/test # cat system.c
#include 
main()
{
 system("echo {a,b,c}{a,b,c}{a,b,c} ");
}
linux-7ap5:/home/user/test # make system
cc system.c   -o system
linux-7ap5:/home/user/test # ./system
aaa aab aac aba abb abc aca acb acc baa bab bac bba bbb bbc bca bcb bcc caa
cab cac cba cbb cbc cca ccb ccc
linux-7ap5:/home/user/test #



On Wed, Sep 14, 2011 at 10:54 PM, saurabh singh  wrote:

> If you go a bit deeper into the system calls that system makes you will
> realize that the argument is actually expanded as "sh -c echo
> {abc}{abc}{abc}
> The expansion facility is provided by bash but not sh.(You may verify my
> claim)
> The default shell is bash.*switch to sh mode and you will realize whats
> happening.*
>
>
> On Thu, Sep 15, 2011 at 2:43 AM, UTKARSH SRIVASTAV <
> usrivastav...@gmail.com> wrote:
>
>> @rahul have you tried it n your system and if yes then which os?
>>
>>
>> On Thu, Sep 15, 2011 at 2:28 AM, UTKARSH SRIVASTAV <
>> usrivastav...@gmail.com> wrote:
>>
>>> yes it's giving wrong output on terminal using gcc compiler in ubuntu
>>>
>>>
>>> On Thu, Sep 15, 2011 at 1:25 AM, Amol Sharma wrote:
>>>
 though it is giving the expected output on the ideone but i am not
 getting the the output on the terminal using gcc compiler it is just
 printing {a,b,c}{a,b,c}{a,b,c} what could be the reason ?

 my OS- Ubuntu 10.04
 @rahul what's ur os ?

 --


 Amol Sharma
 Third Year Student
 Computer Science and Engineering
 MNNIT Allahabad
   
 





 On Thu, Sep 15, 2011 at 1:20 AM, Amol Sharma wrote:

> http://ideone.com/WQxfK
> --
>
>
> Amol Sharma
> Third Year Student
> Computer Science and Engineering
> MNNIT Allahabad
>   
> 
>
>
>
>
>
> On Thu, Sep 15, 2011 at 1:13 AM, rahul vatsa wrote:
>
>> i tried ur code & it gives the same output as wen u execute the
>> command on terminal.
>>
>>
>> On Wed, Sep 14, 2011 at 3:03 PM, UTKARSH SRIVASTAV <
>> usrivastav...@gmail.com> wrote:
>>
>>>
>>> if i write on terminal echo {a,b,c}{a,b,c}{a,b,c} then i get the
>>> output all possible combination of a,b,c and if i write like this
>>>
>>> main()
>>> {
>>>  system("echo {a,b,c}{a,b,c}{a,b,c} ");
>>> }
>>> output : {a,b,c}{a,b,c}{a,b,c}
>>> why?
>>> in system command whatever we write is taken like a command
>>>
>>>
>>> --
>>> *UTKARSH SRIVASTAV
>>> CSE-3
>>> B-Tech 3rd Year
>>> @MNNIT ALLAHABAD*
>>>
>>>
>>>  --
>>> You received this message because you are subscribed to the Google
>>> Groups "Algorithm Geeks" group.
>>> To post to this group, send email to algogeeks@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> algogeeks+unsubscr...@googlegroups.com.
>>> For more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>
>>  --
>> You received this message because you are subscribed to the Google
>> Groups "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from 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.

>>>
>>>
>>>
>>> --
>>> *UTKARSH SRIVASTAV
>>> CSE-3
>>> B-Tech 3rd Year
>>> @MNNIT ALLAHABAD*
>>>
>>>
>>>
>>
>>
>> --
>> *UTKARSH SRIVASTAV
>> CSE-3
>> B-Tech 3rd Year
>> @MNNIT ALLAHABAD*
>>
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>
>
> --
> Saurabh Singh

[algogeeks] InfoCepts Technology Pvt Ltd

2011-09-14 Thread sourabh jain
InfoCepts Technology Pvt Ltd  visited in any college??

tell me procedure 



-- 
Regards
SOURABH KUMAR JAIN
MCA,  NIT RAIPUR
MOB.-+919993878717

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: yahoo campus placements

2011-09-14 Thread Akash Mukherjee
k...bt its a gud 2 weeks lefti guess der wud be sm other clg visits b4
dat

On Wed, Sep 14, 2011 at 9:22 PM, htross  wrote:

> please share the questions asked after the company visits ur campus
>
>
> On Sep 14, 8:53 pm, Akash Mukherjee  wrote:
> > bit mesra, cg 7...dunno nething else :(
> >
> > On Wed, Sep 14, 2011 at 3:00 PM, rahul sharma  >wrote:
> >
> >
> >
> >
> >
> >
> >
> > > in which col it is cumingn wats is its procedure???waht is cgpa
> > > creteria?
> >
> > > On Wed, Sep 14, 2011 at 6:26 PM, Akash Mukherjee  >wrote:
> >
> > >> anybody has any yahoo campus placements papers/questions or tips etc.
> > >> please share
> >
> > >> thanx in advance
> >
> > >> Akash
> >
> > >> --
> > >> You received this message because you are subscribed to the Google
> Groups
> > >> "Algorithm Geeks" group.
> > >> To post to this group, send email to algogeeks@googlegroups.com.
> > >> To unsubscribe from this group, send email to
> > >> algogeeks+unsubscr...@googlegroups.com.
> > >> For more options, visit this group at
> > >>http://groups.google.com/group/algogeeks?hl=en.
> >
> > >  --
> > > You received this message because you are subscribed to the Google
> Groups
> > > "Algorithm Geeks" group.
> > > To post to this group, send email to algogeeks@googlegroups.com.
> > > To unsubscribe from this group, send email to
> > > algogeeks+unsubscr...@googlegroups.com.
> > > For more options, visit this group at
> > >http://groups.google.com/group/algogeeks?hl=en.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

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



Re: [algogeeks]

2011-09-14 Thread Bhavesh agrawal
1) sort each array O(n lg(n))
2) for(i=0;ihttp://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks]

2011-09-14 Thread saurabh singh
If you go a bit deeper into the system calls that system makes you will
realize that the argument is actually expanded as "sh -c echo
{abc}{abc}{abc}
The expansion facility is provided by bash but not sh.(You may verify my
claim)
The default shell is bash.*switch to sh mode and you will realize whats
happening.*

On Thu, Sep 15, 2011 at 2:43 AM, UTKARSH SRIVASTAV
wrote:

> @rahul have you tried it n your system and if yes then which os?
>
>
> On Thu, Sep 15, 2011 at 2:28 AM, UTKARSH SRIVASTAV <
> usrivastav...@gmail.com> wrote:
>
>> yes it's giving wrong output on terminal using gcc compiler in ubuntu
>>
>>
>> On Thu, Sep 15, 2011 at 1:25 AM, Amol Sharma wrote:
>>
>>> though it is giving the expected output on the ideone but i am not
>>> getting the the output on the terminal using gcc compiler it is just
>>> printing {a,b,c}{a,b,c}{a,b,c} what could be the reason ?
>>>
>>> my OS- Ubuntu 10.04
>>> @rahul what's ur os ?
>>>
>>> --
>>>
>>>
>>> Amol Sharma
>>> Third Year Student
>>> Computer Science and Engineering
>>> MNNIT Allahabad
>>>   
>>> 
>>>
>>>
>>>
>>>
>>>
>>> On Thu, Sep 15, 2011 at 1:20 AM, Amol Sharma wrote:
>>>
 http://ideone.com/WQxfK
 --


 Amol Sharma
 Third Year Student
 Computer Science and Engineering
 MNNIT Allahabad
   
 





 On Thu, Sep 15, 2011 at 1:13 AM, rahul vatsa wrote:

> i tried ur code & it gives the same output as wen u execute the command
> on terminal.
>
>
> On Wed, Sep 14, 2011 at 3:03 PM, UTKARSH SRIVASTAV <
> usrivastav...@gmail.com> wrote:
>
>>
>> if i write on terminal echo {a,b,c}{a,b,c}{a,b,c} then i get the
>> output all possible combination of a,b,c and if i write like this
>>
>> main()
>> {
>>  system("echo {a,b,c}{a,b,c}{a,b,c} ");
>> }
>> output : {a,b,c}{a,b,c}{a,b,c}
>> why?
>> in system command whatever we write is taken like a command
>>
>>
>> --
>> *UTKARSH SRIVASTAV
>> CSE-3
>> B-Tech 3rd Year
>> @MNNIT ALLAHABAD*
>>
>>
>>  --
>> You received this message because you are subscribed to the Google
>> Groups "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from 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.
>>>
>>
>>
>>
>> --
>> *UTKARSH SRIVASTAV
>> CSE-3
>> B-Tech 3rd Year
>> @MNNIT ALLAHABAD*
>>
>>
>>
>
>
> --
> *UTKARSH SRIVASTAV
> CSE-3
> B-Tech 3rd Year
> @MNNIT ALLAHABAD*
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>



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

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



Bls: [algogeeks] what is the output????

2011-09-14 Thread Andi Dia


 
Ndua Gunung



Dari: Rohit Upadhyaya 
Kepada: algogeeks@googlegroups.com
Dikirim: Rabu, 14 September 2011 15:07
Judul: Re: [algogeeks] what is the output




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

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



[algogeeks] Re: yahoo campus placements

2011-09-14 Thread htross
please share the questions asked after the company visits ur campus


On Sep 14, 8:53 pm, Akash Mukherjee  wrote:
> bit mesra, cg 7...dunno nething else :(
>
> On Wed, Sep 14, 2011 at 3:00 PM, rahul sharma wrote:
>
>
>
>
>
>
>
> > in which col it is cumingn wats is its procedure???waht is cgpa
> > creteria?
>
> > On Wed, Sep 14, 2011 at 6:26 PM, Akash Mukherjee wrote:
>
> >> anybody has any yahoo campus placements papers/questions or tips etc.
> >> please share
>
> >> thanx in advance
>
> >> Akash
>
> >> --
> >> You received this message because you are subscribed to the Google Groups
> >> "Algorithm Geeks" group.
> >> To post to this group, send email to algogeeks@googlegroups.com.
> >> To unsubscribe from this group, send email to
> >> algogeeks+unsubscr...@googlegroups.com.
> >> For more options, visit this group at
> >>http://groups.google.com/group/algogeeks?hl=en.
>
> >  --
> > You received this message because you are subscribed to the Google Groups
> > "Algorithm Geeks" group.
> > To post to this group, send email to algogeeks@googlegroups.com.
> > To unsubscribe from this group, send email to
> > algogeeks+unsubscr...@googlegroups.com.
> > For more options, visit this group at
> >http://groups.google.com/group/algogeeks?hl=en.

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



Re: [algogeeks]

2011-09-14 Thread UTKARSH SRIVASTAV
@rahul have you tried it n your system and if yes then which os?

On Thu, Sep 15, 2011 at 2:28 AM, UTKARSH SRIVASTAV
wrote:

> yes it's giving wrong output on terminal using gcc compiler in ubuntu
>
>
> On Thu, Sep 15, 2011 at 1:25 AM, Amol Sharma wrote:
>
>> though it is giving the expected output on the ideone but i am not getting
>> the the output on the terminal using gcc compiler it is just printing
>> {a,b,c}{a,b,c}{a,b,c} what could be the reason ?
>>
>> my OS- Ubuntu 10.04
>> @rahul what's ur os ?
>>
>> --
>>
>>
>> Amol Sharma
>> Third Year Student
>> Computer Science and Engineering
>> MNNIT Allahabad
>>   
>> 
>>
>>
>>
>>
>>
>> On Thu, Sep 15, 2011 at 1:20 AM, Amol Sharma wrote:
>>
>>> http://ideone.com/WQxfK
>>> --
>>>
>>>
>>> Amol Sharma
>>> Third Year Student
>>> Computer Science and Engineering
>>> MNNIT Allahabad
>>>   
>>> 
>>>
>>>
>>>
>>>
>>>
>>> On Thu, Sep 15, 2011 at 1:13 AM, rahul vatsa wrote:
>>>
 i tried ur code & it gives the same output as wen u execute the command
 on terminal.


 On Wed, Sep 14, 2011 at 3:03 PM, UTKARSH SRIVASTAV <
 usrivastav...@gmail.com> wrote:

>
> if i write on terminal echo {a,b,c}{a,b,c}{a,b,c} then i get the output
> all possible combination of a,b,c and if i write like this
>
> main()
> {
>  system("echo {a,b,c}{a,b,c}{a,b,c} ");
> }
> output : {a,b,c}{a,b,c}{a,b,c}
> why?
> in system command whatever we write is taken like a command
>
>
> --
> *UTKARSH SRIVASTAV
> CSE-3
> B-Tech 3rd Year
> @MNNIT ALLAHABAD*
>
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

  --
 You received this message because you are subscribed to the Google
 Groups "Algorithm Geeks" group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from 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.
>>
>
>
>
> --
> *UTKARSH SRIVASTAV
> CSE-3
> B-Tech 3rd Year
> @MNNIT ALLAHABAD*
>
>
>


-- 
*UTKARSH SRIVASTAV
CSE-3
B-Tech 3rd Year
@MNNIT ALLAHABAD*

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



Re: [algogeeks]

2011-09-14 Thread UTKARSH SRIVASTAV
yes it's giving wrong output on terminal using gcc compiler in ubuntu

On Thu, Sep 15, 2011 at 1:25 AM, Amol Sharma  wrote:

> though it is giving the expected output on the ideone but i am not getting
> the the output on the terminal using gcc compiler it is just printing
> {a,b,c}{a,b,c}{a,b,c} what could be the reason ?
>
> my OS- Ubuntu 10.04
> @rahul what's ur os ?
>
> --
>
>
> Amol Sharma
> Third Year Student
> Computer Science and Engineering
> MNNIT Allahabad
>   
> 
>
>
>
>
>
> On Thu, Sep 15, 2011 at 1:20 AM, Amol Sharma wrote:
>
>> http://ideone.com/WQxfK
>> --
>>
>>
>> Amol Sharma
>> Third Year Student
>> Computer Science and Engineering
>> MNNIT Allahabad
>>   
>> 
>>
>>
>>
>>
>>
>> On Thu, Sep 15, 2011 at 1:13 AM, rahul vatsa wrote:
>>
>>> i tried ur code & it gives the same output as wen u execute the command
>>> on terminal.
>>>
>>>
>>> On Wed, Sep 14, 2011 at 3:03 PM, UTKARSH SRIVASTAV <
>>> usrivastav...@gmail.com> wrote:
>>>

 if i write on terminal echo {a,b,c}{a,b,c}{a,b,c} then i get the output
 all possible combination of a,b,c and if i write like this

 main()
 {
  system("echo {a,b,c}{a,b,c}{a,b,c} ");
 }
 output : {a,b,c}{a,b,c}{a,b,c}
 why?
 in system command whatever we write is taken like a command


 --
 *UTKARSH SRIVASTAV
 CSE-3
 B-Tech 3rd Year
 @MNNIT ALLAHABAD*


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

>>>
>>>  --
>>> You received this message because you are subscribed to the Google Groups
>>> "Algorithm Geeks" group.
>>> To post to this group, send email to algogeeks@googlegroups.com.
>>> To unsubscribe from 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.
>



-- 
*UTKARSH SRIVASTAV
CSE-3
B-Tech 3rd Year
@MNNIT ALLAHABAD*

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



[algogeeks] Re: Exchanging bit values in a number

2011-09-14 Thread Gene


On Sep 14, 10:27 pm, Gene  wrote:
> My solution just tests bit i and either sets or clears bit j based on
> the result.  Then it does the same testing bit j and setting or
> clearing bit i.
>
> There are many other possibilities.  It would be slick if C shift
> operators accepted negative shift values. But they don't.  Instead you
> could shift the bits down to position 0 then shift them back up to
> their swapped positions and substitute in the input value. This one
> has a spooky symmetry.
>
> unsigned swap(unsigned x, int i, int j)
> {
>   unsigned bit_i = (1u << i) & x;
>   unsigned bit_j = (1u << j) & x;
>   return (x ^ bit_i ^ bit_j) | (bit_i >> i << j) | (bit_j >> j << i);
>
> }
>

Sorry.  Just noticed this is roughly what Dave did except I used xor
to clear the bits at positions i and j.

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: Exchanging bit values in a number

2011-09-14 Thread Gene
My solution just tests bit i and either sets or clears bit j based on
the result.  Then it does the same testing bit j and setting or
clearing bit i.

There are many other possibilities.  It would be slick if C shift
operators accepted negative shift values. But they don't.  Instead you
could shift the bits down to position 0 then shift them back up to
their swapped positions and substitute in the input value. This one
has a spooky symmetry.

unsigned swap(unsigned x, int i, int j)
{
  unsigned bit_i = (1u << i) & x;
  unsigned bit_j = (1u << j) & x;
  return (x ^ bit_i ^ bit_j) | (bit_i >> i << j) | (bit_j >> j << i);
}


On Sep 13, 9:07 pm, Dave  wrote:
> Replying to myself: I should proofread better _before_ I post. Sorry,
> but the explanation should say
>
> ni is bit i of n. nj is bit j of n. n & ~(ni | nj) removes the two
> bits, and then they are shifted to the exchanged positions and or'd
> in.
>
> Dave
>
> On Sep 13, 2:04 pm, Dave  wrote:
>
>
>
> > @Kumar: How about this:
>
> > int exchange2bits(int n, int i, int j) // exchange bits i and j of n.
> > {
> >     int ni, nj;
> >     ni = n & (1 << i);
> >     nj = n & (1 << j);
> >     return n & ~(ni | nj) | ((ni >> i) << j) | ((nj >> j) << i);
>
> > }
>
> > ni is bit i of n. nj is bit j of n. n & (ni | nj) removes the two
> > bits, and then they are shifted to the exchanged positions and or'd
> > in.
>
> > Dave
>
> > On Sep 13, 1:50 pm, kumar raja  wrote:
>
> > > Suppose a number 'n' is given  and two bits positions i,j present in 
> > > binary
> > > representation of n .
>
> > > Then how to exchange the contents of the two bits i and j.
>
> > > E.g. n= 13
> > > its binary representation is  1101 (just for now consider 8 bit 
> > > number)
>
> > > i= 2,j=6
>
> > > o/p : 0100 1001 = 73
>
> > > please suggest some effective way to do this...
>
> > > --
> > > Regards
> > > Kumar Raja
> > > M.Tech(SIT)
> > > IIT Kharagpur,
> > > 10it60...@iitkgp.ac.in
> > > 7797137043.
> > > 09491690115.- Hide quoted text -
>
> > - Show quoted text -- Hide quoted text -
>
> - Show quoted text -

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



Re: [algogeeks]

2011-09-14 Thread Amol Sharma
though it is giving the expected output on the ideone but i am not getting
the the output on the terminal using gcc compiler it is just printing
{a,b,c}{a,b,c}{a,b,c} what could be the reason ?

my OS- Ubuntu 10.04
@rahul what's ur os ?
--


Amol Sharma
Third Year Student
Computer Science and Engineering
MNNIT Allahabad
 






On Thu, Sep 15, 2011 at 1:20 AM, Amol Sharma  wrote:

> http://ideone.com/WQxfK
> --
>
>
> Amol Sharma
> Third Year Student
> Computer Science and Engineering
> MNNIT Allahabad
>   
> 
>
>
>
>
>
> On Thu, Sep 15, 2011 at 1:13 AM, rahul vatsa wrote:
>
>> i tried ur code & it gives the same output as wen u execute the command on
>> terminal.
>>
>>
>> On Wed, Sep 14, 2011 at 3:03 PM, UTKARSH SRIVASTAV <
>> usrivastav...@gmail.com> wrote:
>>
>>>
>>> if i write on terminal echo {a,b,c}{a,b,c}{a,b,c} then i get the output
>>> all possible combination of a,b,c and if i write like this
>>>
>>> main()
>>> {
>>>  system("echo {a,b,c}{a,b,c}{a,b,c} ");
>>> }
>>> output : {a,b,c}{a,b,c}{a,b,c}
>>> why?
>>> in system command whatever we write is taken like a command
>>>
>>>
>>> --
>>> *UTKARSH SRIVASTAV
>>> CSE-3
>>> B-Tech 3rd Year
>>> @MNNIT ALLAHABAD*
>>>
>>>
>>>  --
>>> You received this message because you are subscribed to the Google Groups
>>> "Algorithm Geeks" group.
>>> To post to this group, send email to algogeeks@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> algogeeks+unsubscr...@googlegroups.com.
>>> For more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>

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



Re: [algogeeks]

2011-09-14 Thread Amol Sharma
http://ideone.com/WQxfK
--


Amol Sharma
Third Year Student
Computer Science and Engineering
MNNIT Allahabad
 






On Thu, Sep 15, 2011 at 1:13 AM, rahul vatsa  wrote:

> i tried ur code & it gives the same output as wen u execute the command on
> terminal.
>
>
> On Wed, Sep 14, 2011 at 3:03 PM, UTKARSH SRIVASTAV <
> usrivastav...@gmail.com> wrote:
>
>>
>> if i write on terminal echo {a,b,c}{a,b,c}{a,b,c} then i get the output
>> all possible combination of a,b,c and if i write like this
>>
>> main()
>> {
>>  system("echo {a,b,c}{a,b,c}{a,b,c} ");
>> }
>> output : {a,b,c}{a,b,c}{a,b,c}
>> why?
>> in system command whatever we write is taken like a command
>>
>>
>> --
>> *UTKARSH SRIVASTAV
>> CSE-3
>> B-Tech 3rd Year
>> @MNNIT ALLAHABAD*
>>
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks]

2011-09-14 Thread rahul vatsa
i tried ur code & it gives the same output as wen u execute the command on
terminal.

On Wed, Sep 14, 2011 at 3:03 PM, UTKARSH SRIVASTAV
wrote:

>
> if i write on terminal echo {a,b,c}{a,b,c}{a,b,c} then i get the output all
> possible combination of a,b,c and if i write like this
>
> main()
> {
>  system("echo {a,b,c}{a,b,c}{a,b,c} ");
> }
> output : {a,b,c}{a,b,c}{a,b,c}
> why?
> in system command whatever we write is taken like a command
>
>
> --
> *UTKARSH SRIVASTAV
> CSE-3
> B-Tech 3rd Year
> @MNNIT ALLAHABAD*
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks]

2011-09-14 Thread Anuj Nagpal
for(i=0;i wrote:

> *Write a program to find out the combination of an element of each array 
> gives a result 0.*
> For example:
>
> array 1: {2,1,4,7}
> array 1: {3,-3,-8,0}
> array 1: {-1,-4,-7,6}
>
>
> Output:
>
> pairs =
>
> {2,-8,6}
> {1,3,-4}
> {4,-3,-1}
> {7,0,-7}
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks] find the error

2011-09-14 Thread rahul vatsa
 ther is no get() function.

On Wed, Sep 14, 2011 at 1:55 PM, Puneet Gautam wrote:

> I think there is no problem with the while statement, even if file is
> not present , it will create a new file...
> The problem is with f.get()but dunno what...?
>
>
> On 9/14/11, sandeep kumar  wrote:
> > if file.txt is not present it gives a seg fault
> > and if the file is present then the problem is with f.get(), use fgetc or
> > fgets etc the program runs without any error
> >
> >
> > *..*
> > *
> > **Regards
> >
> > Sandeep Kumar
> > MTech Computer Science
> > **IIT Madras*
> >
> >
> >
> > Music washes away from the soul the dust of everyday life
> >
> -
> >
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Algorithm Geeks" group.
> > To post to this group, send email to algogeeks@googlegroups.com.
> > To unsubscribe from this group, send email to
> > algogeeks+unsubscr...@googlegroups.com.
> > For more options, visit this group at
> > http://groups.google.com/group/algogeeks?hl=en.
> >
> >
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

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



[algogeeks]

2011-09-14 Thread raj singh
*Write a program to find out the combination of an element of each
array gives a result 0.*
For example:

array 1: {2,1,4,7}
array 1: {3,-3,-8,0}
array 1: {-1,-4,-7,6}


Output:

pairs =

{2,-8,6}
{1,3,-4}
{4,-3,-1}
{7,0,-7}

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] matrix

2011-09-14 Thread guna sekaran
Write a program for adding the outer elements of N*M matrix

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: MICROSOFT in VJTI mumbai

2011-09-14 Thread KK
@Bharatkumar bagana : that is a standard Qs which uses line sweep algo
and has O(n lgn) soln other than the trivial O(n^2) soln... google
that Qs...
@tej bala: out of 10.. 5-6 were output type obj Q... then 1 was what's
full form of GCC... its gnu compiler collection.. i made mistake in
this Q..
@dilip : Thanks :))
They din asked me any dbms, networks, or OS Q as i applied as an
intern but they do ask Qs from these subjects as well...

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: MS test cases type Questions

2011-09-14 Thread KK
U must mention all the boundary cases, very large input cases, -ve nos
and must throw appropriate exception while coding during interviews...
Questions are not too hard in MS... just they dont want buggy code...
even if u allocate memory.. u should take an if condition i.e. if (p !
= NULL)...and avoid such other silly mistakes...

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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 error

2011-09-14 Thread Puneet Gautam
I think there is no problem with the while statement, even if file is
not present , it will create a new file...
The problem is with f.get()but dunno what...?


On 9/14/11, sandeep kumar  wrote:
> if file.txt is not present it gives a seg fault
> and if the file is present then the problem is with f.get(), use fgetc or
> fgets etc the program runs without any error
>
>
> *..*
> *
> **Regards
>
> Sandeep Kumar
> MTech Computer Science
> **IIT Madras*
>
>
>
> Music washes away from the soul the dust of everyday life
> -
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

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



[algogeeks] Re: matrix

2011-09-14 Thread Dave
@Guna: The outer elements are a[i][j] with i = 0 or i = n-1 or j = 0
or j = m-1. Thus, something like this will do the trick:

sum=0;
for( i = 0 ; i < n ; ++i )
sum += a[i][0] + a[i][m-1];
for( j = 1 ; j < m-1 ; ++j )
sum += a[0][j] + a[n-1][j];

Dave

On Sep 14, 12:35 pm, guna sekaran  wrote:
> Write a program for adding the outer elements of N*M matrix

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



Re: [algogeeks] C output

2011-09-14 Thread tech coder
@ prateek absolutely wrong , dear u need to brushup ur basics d is a pointer
,
it's can be 2 or 4 depebding on compiler

On Wed, Sep 14, 2011 at 6:26 AM, PRATEEK VERMA  wrote:

> 9 and 3
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from 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*
*"The Coder"*

*"Life is a Game. The more u play, the more u win, the more u win , the more
successfully u play"*

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] veeru chinta wants to chat

2011-09-14 Thread veeru chinta
---

veeru chinta wants to stay in better touch using some of Google's coolest new
products.

If you already have Gmail or Google Talk, visit:
http://mail.google.com/mail/b-eb7f62dde3-e529b22300-R5hRrNkLa-AUvgLu6HzvDygcHrQ
You'll need to click this link to be able to chat with veeru chinta.

To get Gmail - a free email account from Google with over 2,800 megabytes of
storage - and chat with veeru chinta, visit:
http://mail.google.com/mail/a-eb7f62dde3-e529b22300-R5hRrNkLa-AUvgLu6HzvDygcHrQ

Gmail offers:
- Instant messaging right inside Gmail
- Powerful spam protection
- Built-in search for finding your messages and a helpful way of organizing
  emails into "conversations"
- No pop-up ads or untargeted banners - just text ads and related information
  that are relevant to the content of your messages

All this, and its yours for free. But wait, there's more! By opening a Gmail
account, you also get access to Google Talk, Google's instant messaging
service:

http://www.google.com/talk/

Google Talk offers:
- Web-based chat that you can use anywhere, without a download
- A contact list that's synchronized with your Gmail account
- Free, high quality PC-to-PC voice calls when you download the Google Talk
  client

We're working hard to add new features and make improvements, so we might also
ask for your comments and suggestions periodically. We appreciate your help in
making our products even better!

Thanks,
The Google Team

To learn more about Gmail and Google Talk, visit:
http://mail.google.com/mail/help/about.html
http://www.google.com/talk/about.html

(If clicking the URLs in this message does not work, copy and paste them into
the address bar of your browser).

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: MICROSOFT WRITTEN IN VASAVI

2011-09-14 Thread mohit verma
take an array containing all original upper-case  letters and their smaller
case letters and now the problem is reduced to print all substrings
containing length of original string.

On Wed, Sep 14, 2011 at 8:55 PM, teja bala wrote:

>
> //dis one works check it out..
>
> #include
> #include
> #include
> #include
> void toggler(char* x, int pos)
> {
>   if(pos==0){ printf("%s\n",x); return; }
> //  printf("String is now: %s\n",x);
>   x[pos-1] = toupper(x[pos-1]);
>   toggler(x, pos-1);
>   x[pos-1] = tolower(x[pos-1]);
>   toggler(x, pos-1);
> return;
> }
> int main(void){
>   char str[500];
>   scanf("%s",str);
>   toggler(str, strlen(str));
>   return 0;
> }
>
> On Wed, Sep 14, 2011 at 7:22 PM, Dave  wrote:
>
>> @Teja: Oops. I was wrong. By the time I fix my conceptual error, the
>> code is no shorter than Anshu's.
>>
>> Dave
>>
>> On Sep 14, 8:14 am, teja bala  wrote:
>> > @DAVE
>> >
>> > dis was the o/p for ur prog.
>> >
>> > aBC
>> > abC
>> > abC
>> > abc
>> > abc
>> > abc
>> > abc
>> > abc
>> >
>> > #include
>> > main()
>> > {
>> > int i, n = 3;
>> > char *s="ABC";
>> > for( i = 0 ; i < (1<> > {
>> >  s[i^(i>>1)] ^= 'a' ^ 'A';
>> >  cout << s << endl;
>> >
>> >
>> >
>> > }
>> > }- Hide quoted text -
>> >
>> > - Show quoted text -
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>



-- 

*MOHIT VERMA*

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: Samsung India electronics pvt. ltd

2011-09-14 Thread siva viknesh
can anybody plz tell SISO's package and are they recruiting for s/w
developer???

On Aug 8, 4:57 pm, MANNU  wrote:
> SISO in our college have 50 Apti questions (1 hr) and 20 tech questions, all
> on c (in 30 mins).
>
> Manish Kumar (Placed In SISO)
> NIT DGP
> FINAL YEAR.

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



[algogeeks] Re: complexity of recursion

2011-09-14 Thread Don
The complexity of a simple recursive implementation to find the
fibonacci series is exponential complexity.
But there are faster ways to compute the fibonacci series which are
not exponential, so you really can't say that the complexity of the
fibonacci series is exponential.
Don

On Sep 14, 11:08 am, tech coder  wrote:
> an interseting problem
>
> for a fibonacci series
> the recurrence relation is
> t(n)=t(n-1)+t(n-2)+O(1)
> on solving it gives upper bound of O(n^2)
>
> but when draw tree for the recurcsion we see that it is growing
> exponentially giving a complexity of O(2^n).
>
> so what is the complexity for fibonaacci series n^2 or 2^n
>
> --
> *
>
>  Regards*
> *"The Coder"*
>
> *"Life is a Game. The more u play, the more u win, the more u win , the more
> successfully u play"*

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] complexity of recursion

2011-09-14 Thread shady
it is O(n)
actually we use memoization in recursion to avoid calculating same
subproblem.

On Wed, Sep 14, 2011 at 9:38 PM, tech coder wrote:

>
> an interseting problem
>
> for a fibonacci series
> the recurrence relation is
> t(n)=t(n-1)+t(n-2)+O(1)
> on solving it gives upper bound of O(n^2)
>
> but when draw tree for the recurcsion we see that it is growing
> exponentially giving a complexity of O(2^n).
>
> so what is the complexity for fibonaacci series n^2 or 2^n
>
> --
> *
>
>  Regards*
> *"The Coder"*
>
> *"Life is a Game. The more u play, the more u win, the more u win , the
> more successfully u play"*
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



[algogeeks] Schneider electric !!

2011-09-14 Thread jestincobol nair
Has anyone attended schneider electric placement ?? if yes plz share ur
experience it is coming after 2 days to my coll.

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] OS

2011-09-14 Thread Anup Ghatage
Address Space:
The total addresses taken up by a process is known as a process's address
space

On Wed, Sep 14, 2011 at 7:48 PM, teja bala wrote:

> can any one tell the difference between  ADDRESS SPACE and VIRTUAL
> ADDRESS SPACE?
>
> thx in advance.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>


-- 
Anup Ghatage

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] complexity of recursion

2011-09-14 Thread tech coder
an interseting problem

for a fibonacci series
the recurrence relation is
t(n)=t(n-1)+t(n-2)+O(1)
on solving it gives upper bound of O(n^2)

but when draw tree for the recurcsion we see that it is growing
exponentially giving a complexity of O(2^n).

so what is the complexity for fibonaacci series n^2 or 2^n

-- 
*

 Regards*
*"The Coder"*

*"Life is a Game. The more u play, the more u win, the more u win , the more
successfully u play"*

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] yahoo campus placements

2011-09-14 Thread Akash Mukherjee
bit mesra, cg 7...dunno nething else :(

On Wed, Sep 14, 2011 at 3:00 PM, rahul sharma wrote:

> in which col it is cumingn wats is its procedure???waht is cgpa
> creteria?
>
> On Wed, Sep 14, 2011 at 6:26 PM, Akash Mukherjee wrote:
>
>> anybody has any yahoo campus placements papers/questions or tips etc.
>> please share
>>
>> thanx in advance
>>
>> Akash
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks]

2011-09-14 Thread Victor Manuel Grijalva Altamirano
if you want the longest common subsecuence is a  dynamic problem, there is a
algorithm O(n*n) but you can solve it in (nlogn) with suffix array...

If you want the longest substring read about suffix array, search in google
about it!!!, "chococontest suffix array" <- there is a good tutorial



2011/9/13 Sanjay Rajpal 

> A dynamic programming problem .
>
>
> Sanju
> :)
>
>
>
> On Tue, Sep 13, 2011 at 9:34 AM, prasanth n  wrote:
>
>> use dynamic programming..
>>
>>
>> On Sun, Sep 4, 2011 at 6:46 PM, aditya kumar <
>> aditya.kumar130...@gmail.com> wrote:
>>
>>> How to find longest common substring in two strings ?
>>> i want efficent code and iff possible any method other than using suffix
>>> tree .
>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups
>>> "Algorithm Geeks" group.
>>> To post to this group, send email to algogeeks@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> algogeeks+unsubscr...@googlegroups.com.
>>> For more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>
>>
>>
>> --
>> *prasanth*
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from 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.
>



-- 
Victor Manuel Grijalva Altamirano
Universidad Tecnologica de La Mixteca

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: Which one is better to work for ThoughtWorks or Samsung

2011-09-14 Thread 9ight coder
it depends upon your interst in which profile u r
interested...at another prospective sansung famous cmpny
but TW is not u can grow well in both...


On Sep 14, 10:46 am, tech coder  wrote:
> Which one is better to work for  ThoughtWorks or Samsung.
> ThoughtWorks package 5.86
> Samsung  6.25.
>
> Those who r working in samsung or thoughtworks please reply

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: MICROSOFT WRITTEN IN VASAVI

2011-09-14 Thread teja bala
//dis one works check it out..

#include
#include
#include
#include
void toggler(char* x, int pos)
{
  if(pos==0){ printf("%s\n",x); return; }
//  printf("String is now: %s\n",x);
  x[pos-1] = toupper(x[pos-1]);
  toggler(x, pos-1);
  x[pos-1] = tolower(x[pos-1]);
  toggler(x, pos-1);
return;
}
int main(void){
  char str[500];
  scanf("%s",str);
  toggler(str, strlen(str));
  return 0;
}

On Wed, Sep 14, 2011 at 7:22 PM, Dave  wrote:

> @Teja: Oops. I was wrong. By the time I fix my conceptual error, the
> code is no shorter than Anshu's.
>
> Dave
>
> On Sep 14, 8:14 am, teja bala  wrote:
> > @DAVE
> >
> > dis was the o/p for ur prog.
> >
> > aBC
> > abC
> > abC
> > abc
> > abc
> > abc
> > abc
> > abc
> >
> > #include
> > main()
> > {
> > int i, n = 3;
> > char *s="ABC";
> > for( i = 0 ; i < (1< > {
> >  s[i^(i>>1)] ^= 'a' ^ 'A';
> >  cout << s << endl;
> >
> >
> >
> > }
> > }- Hide quoted text -
> >
> > - Show quoted text -
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] samsung engineering lab interview..

2011-09-14 Thread rahul sharma
its very simplein first round data interpretation n reasoning..
in second test ur c skilss copied questions and 10 from os and
ds..totaly simple...then basic technical interview

On Tue, Sep 13, 2011 at 9:23 PM, Rajeshwar Patra
wrote:

> Questions are asked mostly on os and c programming concepts In os virtual
> memory management and ipc
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks] royal bank of scotland

2011-09-14 Thread rahul sharma
they take elitmus test..and then interviewws

On Wed, Sep 14, 2011 at 12:17 PM, deepikaanand wrote:

> wat is selection procedure of RBS (for internships or placements)
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

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



Re: [algogeeks] yahoo campus placements

2011-09-14 Thread rahul sharma
in which col it is cumingn wats is its procedure???waht is cgpa
creteria?

On Wed, Sep 14, 2011 at 6:26 PM, Akash Mukherjee  wrote:

> anybody has any yahoo campus placements papers/questions or tips etc.
> please share
>
> thanx in advance
>
> Akash
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks] Please share experiences if any body has faced Samsung Engineering Labs(SIEL)

2011-09-14 Thread rahul sharma
hw much package it offeringn wich one cuming to ur college ???sel is
in noida and siso in banglore.hw much it is offering

On Wed, Sep 14, 2011 at 8:17 PM, Prags  wrote:

> @ghsjgl k - Plz tell me abt SISO rounds ???
>
> On Mon, Aug 22, 2011 at 9:36 PM, ghsjgl k  wrote:
>
>> i attended for SISO
>>
>>
>> On Mon, Aug 22, 2011 at 2:08 PM, saurabh  wrote:
>>
>>> Can Please tell about the type of question if any body has faced
>>> SIEL .
>>>
>>> Saurabh sah
>>> NIT 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.
>>>
>>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks] Please share experiences if any body has faced Samsung Engineering Labs(SIEL)

2011-09-14 Thread Prags
@ghsjgl k - Plz tell me abt SISO rounds ???

On Mon, Aug 22, 2011 at 9:36 PM, ghsjgl k  wrote:

> i attended for SISO
>
>
> On Mon, Aug 22, 2011 at 2:08 PM, saurabh  wrote:
>
>> Can Please tell about the type of question if any body has faced
>> SIEL .
>>
>> Saurabh sah
>> NIT 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.
>>
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks] Re: Thoughtworks and Tejas network

2011-09-14 Thread amrit harry
dey would only look for OPPS concept with proper working knowledge and DB
concepts..

On Tue, Sep 13, 2011 at 8:15 PM, Brijesh wrote:

> yes..please anyone post questions asked in  thoughtworks interview
>
>  --
> 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/-/Rpd5yw77HbMJ.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>



-- 
AMRIT

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] Nonuniform distribution

2011-09-14 Thread Don
Given a pseudo-random generator which produces a uniform distribution
from the range 0..2^32-1, build a generator which produces discrete
samples from the integers 0..N-1 according to a user-specified
probability distribution {P0, P1, P2, ... PN-1} (where Px is the
probability of x being generated on any draw). Initialization of the
generator may be of time complexity O(N) and the generator may have
memory use of O(N), but each draw must be constant time O(1).

Don

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] Can we define a bijective function from set(strings) ------> Q?

2011-09-14 Thread AnilKumar B
Hi,

Can we define a bijective function from set(strings) --> Q?

I thought of using a polynomial function, for example:

f(ANIL)=pow(31,0)*ASCII(L)+pow(31,1)*ASCII(I)+pow(31,2)*ASCII(I)+pow(31,3)*ASCII(A),

In this f will be one-one from set(Strings)--->N, but I don't whether is
onto or not? And one more thing for all combinations of Strings the output
of this hash function might be >9,223,372,036,854,775,807, which cannot be
represented in JAVA.

So is it possible to define a bijective from Set(Strings)>Q?

Thanks & Regards,
B Anil Kumar.

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] Tech Mahindra

2011-09-14 Thread Prachi Bhise
Tech Mahidra is going to visit in my collage for recruitment.
Does anyone knows which type of question ask in written test and interview.

With Regards
Prachi Bhise
B.E (I.T)
Pune University

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] OS

2011-09-14 Thread teja bala
can any one tell the difference between  ADDRESS SPACE and VIRTUAL
ADDRESS SPACE?

thx in advance.

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



[algogeeks] plz help...

2011-09-14 Thread Tushar Kanta Rath
hello,

i want a good reference in web designing.can anyone plzz help me
with some good links, for reference..

plzz its urgent

Thanks in Advance

-- 
Tushar Kanta Rath,
Master In Computer Application
MNNIT, Allahabad

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



[algogeeks] Re: MICROSOFT WRITTEN IN VASAVI

2011-09-14 Thread Dave
@Teja: Oops. I was wrong. By the time I fix my conceptual error, the
code is no shorter than Anshu's.

Dave

On Sep 14, 8:14 am, teja bala  wrote:
> @DAVE
>
> dis was the o/p for ur prog.
>
> aBC
> abC
> abC
> abc
> abc
> abc
> abc
> abc
>
> #include
> main()
> {
> int i, n = 3;
> char *s="ABC";
> for( i = 0 ; i < (1< {
>  s[i^(i>>1)] ^= 'a' ^ 'A';
>  cout << s << endl;
>
>
>
> }
> }- Hide quoted text -
>
> - Show quoted text -

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



Re: [algogeeks] Re: informatica pattern and question of interview

2011-09-14 Thread abhinav gupta
Informatica sucks.I have topped in its offcampus written test still they din
call me.

On Wed, Sep 14, 2011 at 7:05 PM, ravi maggon  wrote:

> In Thapar Criteria was
> BE CSE and I think MCA was also eligible but for interviews only BE CSE
> were shortlisted.
> Package: 7.75 lpa
>
> On Wed, Sep 14, 2011 at 6:56 PM, sush57  wrote:
>
>> many i know what's the criteria and package for the company...
>>
>> regards
>> sushaanth
>> BE-computer science
>> Madras Institute of technology
>>
>>
>> On Sep 14, 3:02 pm, Ankit Agarwal  wrote:
>> > 2  question
>> >
>> > numbers are (a1+1)*a2*a3... an = a1*a2*a3...an + a2*a3...an
>> > the first term is same...
>> > for second term is (a1*a2...an)/(a1)
>> > now we have to find max of ( ((a1*a2..an)/a1),  (a1*a2...an)/a2)
>> > so the question of max becomes min of( a1, a2, a3... an)
>> >
>> > --
>> > Ankit Agarwal
>> > Computer Science & Engg.
>> > Integrated Dual Degree, V yr
>> > Department of Electronics & Computer Engineering
>> > Indian Institute of Technology Roorkee
>> > Ph. no. +91-9580098805
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from 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
> Ravi Maggon
> B.E. CSE, Final Year
> Thapar University
>
> www.algorithmguru.com
>
> "*Failure is the opportunity to begin again more intelligently"*
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>



-- 
@ |3  # ! /\/ @ \./

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: informatica pattern and question of interview

2011-09-14 Thread sush57
many i know what's the criteria and package for the company...

regards
sushaanth
BE-computer science
Madras Institute of technology

On Sep 14, 3:02 pm, Ankit Agarwal  wrote:
> 2  question
>
> numbers are (a1+1)*a2*a3... an = a1*a2*a3...an + a2*a3...an
> the first term is same...
> for second term is (a1*a2...an)/(a1)
> now we have to find max of ( ((a1*a2..an)/a1),  (a1*a2...an)/a2)
> so the question of max becomes min of( a1, a2, a3... an)
>
> --
> Ankit Agarwal
> Computer Science & Engg.
> Integrated Dual Degree, V yr
> Department of Electronics & Computer Engineering
> Indian Institute of Technology Roorkee
> Ph. no. +91-9580098805

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: MICROSOFT WRITTEN IN VASAVI

2011-09-14 Thread Shravan Kumar
1 wahat is the logic why 1<
>
> On Wed, Sep 14, 2011 at 6:44 PM, teja bala wrote:
>
>> @DAVE
>>
>> dis was the o/p for ur prog.
>>
>> aBC
>> abC
>> abC
>> abc
>> abc
>> abc
>> abc
>> abc
>>
>> #include
>> main()
>> {
>> int i, n = 3;
>> char *s="ABC";
>> for( i = 0 ; i < (1<> {
>>  s[i^(i>>1)] ^= 'a' ^ 'A';
>>  cout << s << endl;
>>  }
>> }
>>
>>
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>
>
> --
> *UTKARSH SRIVASTAV
> CSE-3
> B-Tech 3rd Year
> @MNNIT ALLAHABAD*
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: informatica pattern and question of interview

2011-09-14 Thread ravi maggon
In Thapar Criteria was
BE CSE and I think MCA was also eligible but for interviews only BE CSE were
shortlisted.
Package: 7.75 lpa

On Wed, Sep 14, 2011 at 6:56 PM, sush57  wrote:

> many i know what's the criteria and package for the company...
>
> regards
> sushaanth
> BE-computer science
> Madras Institute of technology
>
> On Sep 14, 3:02 pm, Ankit Agarwal  wrote:
> > 2  question
> >
> > numbers are (a1+1)*a2*a3... an = a1*a2*a3...an + a2*a3...an
> > the first term is same...
> > for second term is (a1*a2...an)/(a1)
> > now we have to find max of ( ((a1*a2..an)/a1),  (a1*a2...an)/a2)
> > so the question of max becomes min of( a1, a2, a3... an)
> >
> > --
> > Ankit Agarwal
> > Computer Science & Engg.
> > Integrated Dual Degree, V yr
> > Department of Electronics & Computer Engineering
> > Indian Institute of Technology Roorkee
> > Ph. no. +91-9580098805
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from 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
Ravi Maggon
B.E. CSE, Final Year
Thapar University

www.algorithmguru.com

"*Failure is the opportunity to begin again more intelligently"*

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: MICROSOFT WRITTEN IN VASAVI

2011-09-14 Thread UTKARSH SRIVASTAV
wahat is the logic why 1 @DAVE
>
> dis was the o/p for ur prog.
>
> aBC
> abC
> abC
> abc
> abc
> abc
> abc
> abc
>
> #include
> main()
> {
> int i, n = 3;
> char *s="ABC";
> for( i = 0 ; i < (1< {
>  s[i^(i>>1)] ^= 'a' ^ 'A';
>  cout << s << endl;
>  }
> }
>
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>



-- 
*UTKARSH SRIVASTAV
CSE-3
B-Tech 3rd Year
@MNNIT ALLAHABAD*

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



Re: [algogeeks] Re: MICROSOFT WRITTEN IN VASAVI

2011-09-14 Thread teja bala
@DAVE

dis was the o/p for ur prog.

aBC
abC
abC
abc
abc
abc
abc
abc

#include
main()
{
int i, n = 3;
char *s="ABC";
for( i = 0 ; i < (1<>1)] ^= 'a' ^ 'A';
 cout << s << endl;
}
}

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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 error

2011-09-14 Thread sandeep kumar
if file.txt is not present it gives a seg fault
and if the file is present then the problem is with f.get(), use fgetc or
fgets etc the program runs without any error


*..*
*
**Regards

Sandeep Kumar
MTech Computer Science
**IIT Madras*



Music washes away from the soul the dust of everyday life
-

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] program

2011-09-14 Thread abhinav gupta
Create a structure
with num,count(of num) and link
parse the array and create nodes (nodes are created with id=num).
when the no of nodes == 3 print the nodes data and count.

On Wed, Sep 14, 2011 at 5:13 PM, parag khanna wrote:

>
> find the frequencies of each alphabet ... n store it in an array
> corressponding to the ascii value of the alphabet as a index of array ... n
> store its count ... then sort the array in decreasing order ... and return
> the top 3 index value of the array in integer form
>
>
>
>
> --
>
>> Parag Khanna
>> B.tech Final Year
>> NIT,Kurukshetra
>
>
> --
>  You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>



-- 
@ |3  # ! /\/ @ \./

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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 error

2011-09-14 Thread JITESH KUMAR
I guess, if file is not found, fopen will return -1.
Which will evaluate the statement
if(f=fopen("file.txt","r")) as true..

-- 
*Regards
Jitesh Kumar

"There is only one 'YOU' in this world. You are Unique and Special.*
*Don't Ever Forget it."*

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



[algogeeks] yahoo campus placements

2011-09-14 Thread Akash Mukherjee
anybody has any yahoo campus placements papers/questions or tips etc. please
share

thanx in advance

Akash

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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 error

2011-09-14 Thread ravi maggon
sorry fclose was also written in the last line. I missed it while asking.

On Wed, Sep 14, 2011 at 6:10 PM, abhinav gupta wrote:

> file not closed.
>
> On Wed, Sep 14, 2011 at 5:56 PM, ravi maggon  wrote:
>
>> Something like this was asked in written test of Tally. We had to find the
>> cause why this program crased during run time.
>> File *f;
>> int count=0;
>> if(f=fopen("file.txt","r"))
>> {
>>   while(f.get()!=EOF)
>>   {
>> count++;
>>   }
>> }
>>
>> --
>> Regards
>> Ravi Maggon
>> B.E. CSE, Final Year
>> Thapar University
>>
>> www.algorithmguru.com
>>
>> "*Failure is the opportunity to begin again more intelligently"*
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>
>
> --
> @ |3  # ! /\/ @ \./
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from 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
Ravi Maggon
B.E. CSE, Final Year
Thapar University

www.algorithmguru.com

"*Failure is the opportunity to begin again more intelligently"*

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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 error

2011-09-14 Thread abhinav gupta
file not closed.

On Wed, Sep 14, 2011 at 5:56 PM, ravi maggon  wrote:

> Something like this was asked in written test of Tally. We had to find the
> cause why this program crased during run time.
> File *f;
> int count=0;
> if(f=fopen("file.txt","r"))
> {
>   while(f.get()!=EOF)
>   {
> count++;
>   }
> }
>
> --
> Regards
> Ravi Maggon
> B.E. CSE, Final Year
> Thapar University
>
> www.algorithmguru.com
>
> "*Failure is the opportunity to begin again more intelligently"*
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>



-- 
@ |3  # ! /\/ @ \./

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] ms question

2011-09-14 Thread Akash Mukherjee
thanx...it was very helpful :)

On Mon, Sep 12, 2011 at 8:46 PM, Piyush Grover wrote:

> A can remain same in following cases:
> -> If m, n are equal in all the N iterations
> -> if m, n are equal in N-2 iterations but in 1 iteration m and n both are
> different in that case there should be one iteration where m and n should be
> same as the previous
> iteration so that they are swapped again to the same position.
>
> In the similar fashion if you think, the pairwise similar iteration should
> be there.
> Now, if in all N iterations probability that m = n is: (N/N*N) *
> (1/N)*...(1/N) = (1/N)^N
> two of the iterations have different m and n then probability is: NC2 *
> (1/N)^(N-2) * {(1 - 1/N)* 1/NC2} = NC2 * (1/N)^N * 2
> similarly, four of the iterations have different m and n then probability
> NC4 * (1/N)^(N-4) *{(1 - 1/N) * 1/NC2}^2 = NC4 * (1/N)^N * 2^2
>
> -Piyush
>
>
> On Mon, Sep 12, 2011 at 10:24 PM, payal gupta  wrote:
>
>> @piyush..
>> cud u plzz..xplain...n elaborate
>>
>> Regards,
>>
>> Payal Gupta
>>
>>
>> On Mon, Sep 12, 2011 at 10:15 PM, Piyush Grover <
>> piyush4u.iit...@gmail.com> wrote:
>>
>>> Sry i was little wrong:
>>>
>>> nC0*(1/n)^n + nC2 *2*(1/n)^n + nC4*2^2*(1/n)^n++nCn*2^(n/2)*(1/n)^n
>>> when n is even
>>>
>>> nC0*(1/n)^n + nC2 *2*(1/n)^n +
>>> nC4*2^2*(1/n)^n++nCn-1*2^(n-1/2)*(1/n)^n   when n is odd
>>>
>>>
>>> On Mon, Sep 12, 2011 at 10:08 PM, Piyush Grover <
>>> piyush4u.iit...@gmail.com> wrote:
>>>
 it should be:

 (1/n)^n * (1 + 2 + 2^2 + 2^3 +(n/2)+1 terms) = {2^(1 + n/2) -
 1}*(1/n)^n   when n even

 (1/n)^n * (1 + 2 + 2^2 + 2^3 +(n-1/2)+1 terms) = {2^(1 + (n-1)/2)  -
 1}*(1/n)^n   when n is odd


 -Piyush


 On Mon, Sep 12, 2011 at 8:01 PM, sandeep nagamalli <
 nsandee...@gmail.com> wrote:

> I think it is 1 / (2N)
>
> (1/N) * (1/N)*(N/2) = 1/(2N)
>
>
> On Mon, Sep 12, 2011 at 6:33 PM, Akash Mukherjee 
> wrote:
>
>> this is a case, but isnt der a case of circular permutation 2??
>> what say abt dis
>> 0,1
>> 2,3
>> 4,5
>> 0,1
>> 2,3
>> 4,5
>>
>> it wrks i gues??
>>
>>
>> On Mon, Sep 12, 2011 at 12:56 PM, teja bala <
>> pawanjalsa.t...@gmail.com> wrote:
>>
>>>
>>>
>>> I think it is 1/N
>>>
>>>  let N=6 that means rand(6)= takes values 0-5 i.e 6 values.
>>> rand(m)=6 values
>>> rand(n)=6 values
>>> total combinations 6*6=36 values set but among dem array will change
>>> only for
>>> (0,0)(1,1)(2,2)(3,3)(4,4)(5,5)(6,6)=6values of N
>>>
>>> So 6/36=1/6
>>>
>>> If we generalize it 1/N
>>>
>>> correct me if i'm 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.
>>>
>>
>>  --
>> You received this message because you are subscribed to the Google
>> Groups "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from 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&Regards:
> -sandeep
>
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from 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 em

[algogeeks] find the error

2011-09-14 Thread ravi maggon
Something like this was asked in written test of Tally. We had to find the
cause why this program crased during run time.
File *f;
int count=0;
if(f=fopen("file.txt","r"))
{
  while(f.get()!=EOF)
  {
count++;
  }
}

-- 
Regards
Ravi Maggon
B.E. CSE, Final Year
Thapar University

www.algorithmguru.com

"*Failure is the opportunity to begin again more intelligently"*

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: branching factor when BFS and DFS of a graph is same

2011-09-14 Thread bugaboo
@siddharam:

Performing inorder and pre/postorder will still have false positives.

Consider 2 trees one with root node "a" with node "b" as left child,
another tree with root node "a" with node "b" as its right child.

Anyway, for binary trees, I am aware of a recursive solution to find
out similarity or isomorphism. Not sure how this extends for a graph.
Always thought a DFS and/or BFS should suffice but apparently not.

On Sep 14, 1:43 am, siddharam suresh  wrote:
> bharath.sriram,
> perform inorder traversal and peorder/postorder traversal on both tree then
> compare both the result of two tree.
> Thank you,
> Sid.
>
>
>
>
>
>
>
> On Wed, Sep 14, 2011 at 10:22 AM, bugaboo  wrote:
> > This brings up another interesting question. How do you find out if 2
> > graphs are identical? (By identical, I mean exact similarity and NOT
> > isomorphism). Clearly, checking to see if both the DFS traversal and
> > BFS traversal match seem to have false positives as Bharathkumar
> > mentioned.
>
> > On Sep 13, 12:50 am, bharatkumar bagana 
> > wrote:
> > > @nishaanth:
> > > ex:
> > >    1
> > > 2    3
> > >          4
> > >             5
> > > bfs:12345
> > > dfs:12345
> > > branching factor of this tree  is not 1 ..
>
> > > On Tue, Sep 13, 2011 at 9:38 AM, nishaanth 
> > wrote:
> > > > yes branching factor should be 1. it can be not equal to 1 only for the
> > > > penultimate node. by penultimate node i mean whose children are the
> > leaves
> > > > of the tree. rest all cases it should be 1.
>
> > > > On Tue, Sep 13, 2011 at 9:24 AM, siddharam suresh <
> > siddharam@gmail.com
> > > > > wrote:
>
> > > >> cant say if there more than one leaf element
> > > >> still both the algo give same result
> > > >> Thank you,
> > > >> Sid.
>
> > > >> On Tue, Sep 13, 2011 at 7:52 AM, Sundi  wrote:
>
> > > >>> if the dfs and bfs of a graph is same, does it mean that if the
> > > >>> branching factor of a graph is one?
>
> > > >>> a>b>c>d
>
> > > >>> example: both dfs abd bfs are same 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.
>
> > > >>  --
> > > >> You received this message because you are subscribed to the Google
> > Groups
> > > >> "Algorithm Geeks" group.
> > > >> To post to this group, send email to algogeeks@googlegroups.com.
> > > >> To unsubscribe from this group, send email to
> > > >> algogeeks+unsubscr...@googlegroups.com.
> > > >> For more options, visit this group at
> > > >>http://groups.google.com/group/algogeeks?hl=en.
>
> > > > --
> > > > S.Nishaanth,
> > > > Computer Science and engineering,
> > > > IIT Madras.
>
> > > > --
> > > > You received this message because you are subscribed to the Google
> > Groups
> > > > "Algorithm Geeks" group.
> > > > To post to this group, send email to algogeeks@googlegroups.com.
> > > > To unsubscribe from this group, send email to
> > > > algogeeks+unsubscr...@googlegroups.com.
> > > > For more options, visit this group at
> > > >http://groups.google.com/group/algogeeks?hl=en.
>
> > > --
>
> > > **Please do not print this e-mail until urgent requirement. Go Green!!
> > > Save Papers <=> Save Trees
> > > *BharatKumar Bagana*
> > > **http://www.google.com/profiles/bagana.bharatkumar<
> >http://www.google.com/profiles/bagana.bharatkumar>
> > > *
> > > Mobile +91 8056127652*
> > > 
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Algorithm Geeks" group.
> > To post to this group, send email to algogeeks@googlegroups.com.
> > To unsubscribe from this group, send email to
> > algogeeks+unsubscr...@googlegroups.com.
> > For more options, visit this group at
> >http://groups.google.com/group/algogeeks?hl=en.

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



[algogeeks] juniper networks

2011-09-14 Thread ravi maggon
Did juniper visit any campus for training or job recruitment?

-- 
Regards
Ravi Maggon
B.E. CSE, Final Year
Thapar University

www.algorithmguru.com

"*Failure is the opportunity to begin again more intelligently"*

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] program

2011-09-14 Thread parag khanna
find the frequencies of each alphabet ... n store it in an array
corressponding to the ascii value of the alphabet as a index of array ... n
store its count ... then sort the array in decreasing order ... and return
the top 3 index value of the array in integer form




-- 

> Parag Khanna
> B.tech Final Year
> NIT,Kurukshetra

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] program

2011-09-14 Thread sukran dhawan
heap construction ...

On Wed, Sep 14, 2011 at 4:44 PM, bharatkumar bagana <
bagana.bharatku...@gmail.com> wrote:

> with space O(n) and time O(n), we can trace the whole array and maintain
> the freq of each number and by one more trace with using 3 variables ,
> we can find top 3 
>
>
> On Wed, Sep 14, 2011 at 11:20 AM, raj  wrote:
>
>> program to find the top 3 repeating number from the given array
>> eg
>> You r given an array and u have to find out the top 3 repeated
>> numbers.
>>  for ex: GAURAV[]={20,8,3,7,8,9,20,6,4,6,20,8,20}
>> so the output will be: 20 is repeated 4 times 8 is repeated 3 times 6
>> is repeated 2 times.
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>>
>
>
> --
>
> **Please do not print this e-mail until urgent requirement. Go Green!!
> Save Papers <=> Save Trees
> *BharatKumar Bagana*
> **http://www.google.com/profiles/bagana.bharatkumar
> *
> Mobile +91 8056127652*
> 
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks] Matrix

2011-09-14 Thread sukran dhawan
wat do u mean by reversing a matrix ?

On Wed, Sep 14, 2011 at 4:51 PM, bharatkumar bagana <
bagana.bharatku...@gmail.com> wrote:

> will u pls provide one example .. so that every one understand ...
>
>
> On Wed, Sep 14, 2011 at 1:29 PM, guna sekaran  wrote:
>
>> Write a program for reversing the matrix
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>>
>
>
> --
>
> **Please do not print this e-mail until urgent requirement. Go Green!!
> Save Papers <=> Save Trees
> *BharatKumar Bagana*
> **http://www.google.com/profiles/bagana.bharatkumar
> *
> Mobile +91 8056127652*
> 
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks] Matrix

2011-09-14 Thread bharatkumar bagana
will u pls provide one example .. so that every one understand ...

On Wed, Sep 14, 2011 at 1:29 PM, guna sekaran  wrote:

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


-- 

**Please do not print this e-mail until urgent requirement. Go Green!!
Save Papers <=> Save Trees
*BharatKumar Bagana*
**http://www.google.com/profiles/bagana.bharatkumar
*
Mobile +91 8056127652*


-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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] program

2011-09-14 Thread bharatkumar bagana
with space O(n) and time O(n), we can trace the whole array and maintain the
freq of each number and by one more trace with using 3 variables , we
can find top 3 

On Wed, Sep 14, 2011 at 11:20 AM, raj  wrote:

> program to find the top 3 repeating number from the given array
> eg
> You r given an array and u have to find out the top 3 repeated
> numbers.
>  for ex: GAURAV[]={20,8,3,7,8,9,20,6,4,6,20,8,20}
> so the output will be: 20 is repeated 4 times 8 is repeated 3 times 6
> is repeated 2 times.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>


-- 

**Please do not print this e-mail until urgent requirement. Go Green!!
Save Papers <=> Save Trees
*BharatKumar Bagana*
**http://www.google.com/profiles/bagana.bharatkumar
*
Mobile +91 8056127652*


-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: Microsoft Question

2011-09-14 Thread bharatkumar bagana
The well known examples of priority queue is minheap and maxheap..
i guess the question is how do we implement one of these(at least) using
queue?

On Wed, Sep 14, 2011 at 9:08 AM, Ankuj Gupta  wrote:

> I guess the functionality of priority should be maintained
>
> On Sep 13, 11:59 pm, Ankur Garg  wrote:
> > But dude are u saying stack will be implemented as a map with
> > 
> >
> > and then choose element based on priority ?
> >
> > regards
> > Ankur
> >
> >
> >
> >
> >
> >
> >
> > On Tue, Sep 13, 2011 at 10:16 PM, Ankuj Gupta 
> wrote:
> >
> > > For stack :- Keep incrementing the priority of each pushed element. So
> > > the last pushed element will have the greatest priority and the
> > > element pushed first will have
> > > lowest priority.
> > > For queue:- keep decrementing the priority of each inserted element.
> >
> > > On Sep 13, 1:45 am, Ankur Garg  wrote:
> > > > How to Implement a Queue with a Priority Queue
> > > > Similarly how woud you implement Stack with Priority Queue
> >
> > > --
> > > You received this message because you are subscribed to the Google
> Groups
> > > "Algorithm Geeks" group.
> > > To post to this group, send email to algogeeks@googlegroups.com.
> > > To unsubscribe from 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.
>
>


-- 

**Please do not print this e-mail until urgent requirement. Go Green!!
Save Papers <=> Save Trees
*BharatKumar Bagana*
**http://www.google.com/profiles/bagana.bharatkumar
*
Mobile +91 8056127652*


-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: Finding connection b/w 2 profiles

2011-09-14 Thread JITESH KUMAR
Using DFS we can stuck in the blind ally as there is not limit of depth..

On Wed, Sep 14, 2011 at 4:16 PM, tech coder wrote:

> we can also use dfs and find if there exist  path  between given two
> nodes(profiles here).
> if yea , there is a connection b/w two profiles.
>
>
> On Wed, Sep 14, 2011 at 1:58 PM, Azhar Hussain  wrote:
>
>> Union Find Algorithm would do
>>
>> -
>> Azhar.
>>
>>
>> On Wed, Sep 14, 2011 at 1:42 PM, JITESH KUMAR  wrote:
>>
>>> Neither depth is known nor we have to find the shortest path. We just
>>> have to find the path.
>>>
>>>
>>> --
>>> *Regards
>>> Jitesh Kumar
>>> *
>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups
>>> "Algorithm Geeks" group.
>>> To post to this group, send email to algogeeks@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> algogeeks+unsubscr...@googlegroups.com.
>>> For more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>



-- 
*Regards
Jitesh Kumar

"There is only one 'YOU' in this world. You are Unique and Special.*
*Don't Ever Forget it."*

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



[algogeeks] Re: MICROSOFT WRITTEN IN VASAVI

2011-09-14 Thread Dave
Shorter. It is assumed that the input string consists of upper and
lower case letters only.

void allCase(string r)
{
int i, n = s.sise();
for( i = 0 ; i < (1<>1)] ^= 'a' ^ 'A';
cout << s << endl;
}
}

The expression i^(i>>1) is a Gray-code (see 
http://en.wikipedia.org/wiki/Gray_code)
conversion. In Gray code, the numbers from 0 to 2^n - 1 are arranged
in an order so that only one bit changes from number to number. So
this code changes the case of one character at a time, and after 2^n
iterations, has printed all of the combinations of cases.

Dave

On Sep 14, 5:39 am, anshu mishra  wrote:
> void allCase(string r)
> {
>     int n = s.sise();
>     string s;
>     for (i = 0; i < (1 << n); i++)
>     {
>          s = r;
>           for ( j = 0; j < n; j++)
>           {
>                 if ( i & ( 1 << j) )
>                 {
>                       s[j] = s[j] + ('a' - 'A');
>                 }
>           }
>           cout << s << endl;
>     }
>
>
>
> }- Hide quoted text -
>
> - Show quoted text -

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



Re: [algogeeks] Re: what is the output????

2011-09-14 Thread rahul vatsa
9,8,7,6,5,4,3,2,1 hello by the 9 child prs

On Wed, Sep 14, 2011 at 4:07 AM, htross  wrote:

> how is it 45
>
> On Sep 14, 12:56 pm, rahul vatsa  wrote:
> > 45 times
> >
> > On Wed, Sep 14, 2011 at 3:35 AM, sharmila saru  >wrote:
> >
> >
> >
> >
> >
> >
> >
> > > hello will be printed 9 times
> >
> > > On Sun, Sep 11, 2011 at 3:25 AM, htross  wrote:
> >
> > >> main()
> > >> {
> > >>int tmp;
> > >>for(i=0;i<9;i++)
> > >>{
> > >>tmp=fork();
> > >>if(tmp>0)
> > >>break;
> > >>printf("Hello");
> > >>}
> > >> }
> >
> > >> --
> > >> You received this message because you are subscribed to the Google
> Groups
> > >> "Algorithm Geeks" group.
> > >> To post to this group, send email to algogeeks@googlegroups.com.
> > >> To unsubscribe from this group, send email to
> > >> algogeeks+unsubscr...@googlegroups.com.
> > >> For more options, visit this group at
> > >>http://groups.google.com/group/algogeeks?hl=en.
> >
> > >  --
> > > You received this message because you are subscribed to the Google
> Groups
> > > "Algorithm Geeks" group.
> > > To post to this group, send email to algogeeks@googlegroups.com.
> > > To unsubscribe from this group, send email to
> > > algogeeks+unsubscr...@googlegroups.com.
> > > For more options, visit this group at
> > >http://groups.google.com/group/algogeeks?hl=en.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

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



Re: [algogeeks] Re: Finding connection b/w 2 profiles

2011-09-14 Thread tech coder
we can also use dfs and find if there exist  path  between given two
nodes(profiles here).
if yea , there is a connection b/w two profiles.

On Wed, Sep 14, 2011 at 1:58 PM, Azhar Hussain  wrote:

> Union Find Algorithm would do
>
> -
> Azhar.
>
>
> On Wed, Sep 14, 2011 at 1:42 PM, JITESH KUMAR  wrote:
>
>> Neither depth is known nor we have to find the shortest path. We just have
>> to find the path.
>>
>>
>> --
>> *Regards
>> Jitesh Kumar
>> *
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks] MICROSOFT WRITTEN IN VASAVI

2011-09-14 Thread anshu mishra
void allCase(string r)
{
int n = s.sise();
string s;
for (i = 0; i < (1 << n); i++)
{
 s = r;
  for ( j = 0; j < n; j++)
  {
if ( i & ( 1 << j) )
{
  s[j] = s[j] + ('a' - 'A');
}
  }
  cout << s << endl;
}
}

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



[algogeeks] MICROSOFT WRITTEN IN VASAVI

2011-09-14 Thread teja bala
dis was asked in MS written


U r given a string u need to print all cases of letters without
changing the order
eg:-
ABC,Abc,ABc,aBC,abC etc...

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



Re: [algogeeks] C output

2011-09-14 Thread PRATEEK VERMA
9 and 3

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: informatica pattern and question of interview

2011-09-14 Thread Ankit Agarwal
2  question

numbers are (a1+1)*a2*a3... an = a1*a2*a3...an + a2*a3...an
the first term is same...
for second term is (a1*a2...an)/(a1)
now we have to find max of ( ((a1*a2..an)/a1),  (a1*a2...an)/a2)
so the question of max becomes min of( a1, a2, a3... an)


-- 
Ankit Agarwal
Computer Science & Engg.
Integrated Dual Degree, V yr
Department of Electronics & Computer Engineering
Indian Institute of Technology Roorkee
Ph. no. +91-9580098805

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: Amazon ques

2011-09-14 Thread surender sanke
however maximum subarray can be found in O(n)
just needs to get maximum difference in entries of each A[i]
[-2]->[5]
[-1]->[0, 2, 4, 6]   maxdiff[-1] = 6-0
[0]->[-1, 1, 3, 7]   maxdiff[0] = 7-(-1)
[1]->[8, 10]  maxdiff[1] = 10-8
[2]->[9]
max(maxdiff[i]) = 8

surender

On Sun, Sep 11, 2011 at 4:31 PM, Ankur Garg  wrote:

> Yeah :(
> U r right dude ...I dont think O(n) solution can exist for this problem
>
>
>
> On Sun, Sep 11, 2011 at 4:27 PM, Kunal Patil  wrote:
>
>> As the author correctly mentions it:
>> "Building the array is O(n) , but printing these intervals must be done
>> in linear time to the number of intervals."
>> Assuming n means number of elements in the original array
>> There are O(n^2) possible intervals, how can you print them in O(n) ???
>>
>>
>> On Sun, Sep 11, 2011 at 4:20 PM, Ankur Garg  wrote:
>>
>>> This solution is not in O(n) time :(
>>> Unfortunately interviewer wants O(n) .
>>>
>>>
>>> On Sun, Sep 11, 2011 at 4:01 PM, Kunal Patil  wrote:
>>>
 @Brijesh: +1


 On Sun, Sep 11, 2011 at 2:14 PM, Brijesh 
 wrote:

>  This is the fastest way I can think of to do this, and it is linear to
> the number of intervals there are.
>
> Let L be your original list of numbers and A be a hash of empty arrays
> where initially A[0] = [0]
>
> sum = 0
> for i in 0..n
>   if L[i] == 0:
> sum--
> A[sum].push(i)
>   elif L[i] == 1:
> sum++
> A[sum].push(i)
>
> Now A is essentially an x y graph of the sum of the sequence (x is the
> index of the list, y is the sum). Every time there are two x values x1 and
> x2 to an y value, you have an interval (x1, x2] where the number of 0s and
> 1s is equal.
>
> There are m(m-1)/2 (arithmetic sum from 1 to m - 1) intervals where the
> sum is 0 in every array M in A where m = M.length
>
> Using your example to calculate A by hand we use this chart
>
> L   #   0  1  0  1  0  0  1  1  1  1  0
> A keys  0  -1  0 -1  0 -1 -2 -1  0  1  2  1
> L index-1   0  1  2  3  4  5  6  7  8  9  10
>
> (I've added a # to represent the start of the list with an key of -1.
> Also removed all the numbers that are not 0 or 1 since they're just
> distractions) A will look like this:
>
> [-2]->[5]
> [-1]->[0, 2, 4, 6]
> [0]->[-1, 1, 3, 7]
> [1]->[8, 10]
> [2]->[9]
>
> For any M = [a1, a2, a3, ...], (ai + 1, aj) where j > i will be an
> interval with the same number of 0s as 1s. For example, in [-1]->[0, 2, 4,
> 6], the intervals are (1, 2), (1, 4), (1, 6), (3, 4), (3, 6), (5, 6).
>
> Building the array A is O(n), but printing these intervals from A must
> be done in linear time to the number of intervals. In fact, that could be
> your proof that it is not quite possible to do this in linear time to n
> because it's possible to have more intervals than n and you need at least
> the number of interval iterations to print them all.
>
> Unless of course you consider building A is enough to find all the
> intervals (since it's obvious from A what the intervals are), then it is
> linear to n
>
> THis is the solution..go through it, its very easy to understand...
> PS: copied from
>
> http://stackoverflow.com/questions/6967853/dynamic-programming-can-interval-of-even-1s-and-0s-be-found-in-linear-time
>
>
>
>
>
> --
> 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/-/wM8Xhc1tUXQJ.
>
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from 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

Re: [algogeeks] Re: MS test cases type Questions

2011-09-14 Thread payal gupta
dats f9...bt cud i get 2 knoe ...how bout answering 2 d perfectness...n  if
v cud practice dem from nywhere

Regards,
PAYAL GUPTA,
CSE-3 rd yr,
NIT-B

On Tue, Sep 13, 2011 at 10:05 PM, Navneet  wrote:

> Basically test cases are asked for very general purpose software like
> a Notepad etc.
>
> Generally they want you to come up with as many as test cases as
> possible.
>
>
> On Sep 13, 7:15 pm, Akash Mukherjee  wrote:
> > +1
> >
> >
> >
> >
> >
> >
> >
> > On Mon, Sep 12, 2011 at 3:42 PM, pg@manit  wrote:
> > > Cud some 1 suggest me 4m how 2 practise test cases type of questions
> > > which usually cum in MS written Papers?
> > > thanx..in advance
> >
> > > Regards,
> > > PAYAL GUPTA
> >
> > > --
> > > You received this message because you are subscribed to the Google
> Groups
> > > "Algorithm Geeks" group.
> > > To post to this group, send email to algogeeks@googlegroups.com.
> > > To unsubscribe from this group, send email to
> > > algogeeks+unsubscr...@googlegroups.com.
> > > For more options, visit this group at
> > >http://groups.google.com/group/algogeeks?hl=en.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from 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: Finding connection b/w 2 profiles

2011-09-14 Thread Azhar Hussain
Union Find Algorithm would do

-
Azhar.

On Wed, Sep 14, 2011 at 1:42 PM, JITESH KUMAR  wrote:

> Neither depth is known nor we have to find the shortest path. We just have
> to find the path.
>
>
> --
> *Regards
> Jitesh Kumar
> *
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

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



Re: [algogeeks] Exchanging bit values in a number

2011-09-14 Thread DeVaNsH gUpTa
#include
int main()
{
int n,i,j,temp,temp1;
scanf("%d %d %d",&n,&i,&j);
temp=(1

Re: [algogeeks] Mentor Graphics Help !!

2011-09-14 Thread rajul jain
If anybody know about placement procedure of mentor graphics pls help

On Mon, Aug 22, 2011 at 11:09 PM, Ankur Garg  wrote:

> Also to add,
>
> If you post profile in their portal no reply comes...How to apply ...can
> any one here refer my candidature for Mentor Graphics ..I have 2 yrs work ex
> working with IBM ISL
>
> Regards
> Ankur
>
>
> On Mon, Aug 22, 2011 at 7:23 PM, Mangal Dass wrote:
>
>> Anybody pls tell me the questions coming into Information-Mosaic campus
>> test.
>> Pls tell me both the pattern as well as questions whatever u r remembered.
>>
>> Thanks a lot,
>>
>> On 8/22/11, sourabh jakhar  wrote:
>> > i also want to know abt the off campus recruitment  of mentor graphics
>> > On Mon, Aug 22, 2011 at 6:49 PM, Decipher 
>> wrote:
>> >
>> >> Can anyone tell me the interview procedure of Mentor Graphics along
>> with
>> >> some interview questions ??
>> >>
>> >> --
>> >> 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/-/NiJZzcypKH0J.
>> >> To post to this group, send email to algogeeks@googlegroups.com.
>> >> To unsubscribe from 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)(Final 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.
>> >
>> >
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from 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.



  1   2   >