peacelover1987...@yahoo.co.in wrote:
This is a variant of that one
--
*From:* saurabh singh saurab...@gmail.com
*To:* algogeeks@googlegroups.com
*Sent:* Friday, 29 June 2012 3:05 PM
*Subject:* Re: [algogeeks] MS Question: Segregrate positive and
negative nos
--
*From:* saurabh singh saurab...@gmail.com
*To:* algogeeks@googlegroups.com
*Sent:* Friday, 29 June 2012 3:05 PM
*Subject:* Re: [algogeeks] MS Question: Segregrate positive and
negative nos in array without changing order
duplicate of a previous post.Kindly refer
: Segregrate positive and
negative nos in array without changing order
duplicate of a previous post.Kindly refer to that post.
Saurabh Singh
B.Tech (Computer Science)
MNNIT
blog:geekinessthecoolway.blogspot.com
On Fri, Jun 29, 2012 at 10:41 AM, raghavan M
peacelover1987...@yahoo.co.in
@amol :
#includestdio.h
int main()
{
int arr[]={5,0,1,2,6,7,8,3,4,9};
int i,j,n,temp;
n=sizeof(arr)/sizeof(arr[0]);
for(j=0;j=1;j++)
{
for(i=0;in;i++)
{
if(arr[i]!=i){
temp=arr[i];
arr[i]=arr[arr[i]];
i don't see any change in the code you posted...other than expanding swap
function
i believe in discussing the idea/algonot the code..
--
Amol Sharma
Final Year Student
Computer Science and Engineering
MNNIT Allahabad
http://gplus.to/amolsharma99
yes it is same and it not working . Apart for this you had provided code
for sorting O(n) time and not the idea/algo.
please explain the algorithm , how you are sorting it within O(n) time and
O(1) space complexity.
On Mon, Jul 2, 2012 at 3:18 PM, Amol Sharma amolsharm...@gmail.com wrote:
i
opssyeah dat was the bug... now got it :)
On Mon, Jul 2, 2012 at 4:08 PM, Amol Sharma amolsharm...@gmail.com wrote:
@atul:
the logic for the O(n) counting is same as for the count sort.
you haven't write the swap function correctly,
here is correct code for swap function --
: [algogeeks] MS Question: Segregrate positive and
negative nos in array without changing order
duplicate of a previous post.Kindly refer to that post.
Saurabh Singh
B.Tech (Computer Science)
MNNIT
blog:geekinessthecoolway.blogspot.com
On Fri, Jun 29, 2012 at 10:41 AM, raghavan M
peacelover1987
PM, raghavan M
peacelover1987...@yahoo.co.in wrote:
This is a variant of that one
--
*From:* saurabh singh saurab...@gmail.com
*To:* algogeeks@googlegroups.com
*Sent:* Friday, 29 June 2012 3:05 PM
*Subject:* Re: [algogeeks] MS Question: Segregrate positive
saurab...@gmail.com
*To:* algogeeks@googlegroups.com
*Sent:* Friday, 29 June 2012 3:05 PM
*Subject:* Re: [algogeeks] MS Question: Segregrate positive and
negative nos in array without changing order
duplicate of a previous post.Kindly refer to that post.
Saurabh Singh
B.Tech (Computer Science
: [algogeeks] MS Question: Segregrate positive and
negative nos in array without changing order
duplicate of a previous post.Kindly refer to that post.
Saurabh Singh
B.Tech (Computer Science)
MNNIT
blog:geekinessthecoolway.blogspot.com
On Fri, Jun 29, 2012 at 10:41 AM, raghavan M
--
*From:* saurabh singh saurab...@gmail.com
*To:* algogeeks@googlegroups.com
*Sent:* Friday, 29 June 2012 3:05 PM
*Subject:* Re: [algogeeks] MS Question: Segregrate positive and
negative nos in array without changing order
duplicate of a previous post.Kindly
--
*From:* saurabh singh saurab...@gmail.com
*To:* algogeeks@googlegroups.com
*Sent:* Friday, 29 June 2012 3:05 PM
*Subject:* Re: [algogeeks] MS Question: Segregrate positive and
negative nos in array without changing order
duplicate of a previous post.Kindly refer to that post
duplicate of a previous post.Kindly refer to that post.
Saurabh Singh
B.Tech (Computer Science)
MNNIT
blog:geekinessthecoolway.blogspot.com
On Fri, Jun 29, 2012 at 10:41 AM, raghavan M
peacelover1987...@yahoo.co.inwrote:
Hi
Question as in subject
*No extra space (can use one extra
one can modify dutch national flag algo for two colors(2 types positive n
negative)
--
You received this message because you are subscribed to the Google Groups
Algorithm Geeks group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to
Quick sort partition routine variation.
On Fri, Jun 29, 2012 at 3:06 PM, Ravi Ranjan ravi.cool2...@gmail.comwrote:
one can modify dutch national flag algo for two colors(2 types positive n
negative)
--
You received this message because you are subscribed to the Google Groups
Algorithm
To: algogeeks@googlegroups.com
Sent: Friday, 29 June 2012 3:06 PM
Subject: Re: [algogeeks] MS Question: Segregrate positive and negative nos in
array without changing order
one can modify dutch national flag algo for two colors(2 types positive n
negative)
--
You received this message because you
This is a variant of that one
From: saurabh singh saurab...@gmail.com
To: algogeeks@googlegroups.com
Sent: Friday, 29 June 2012 3:05 PM
Subject: Re: [algogeeks] MS Question: Segregrate positive and negative nos in
array without changing order
duplicate
of that one
--
*From:* saurabh singh saurab...@gmail.com
*To:* algogeeks@googlegroups.com
*Sent:* Friday, 29 June 2012 3:05 PM
*Subject:* Re: [algogeeks] MS Question: Segregrate positive and negative
nos in array without changing order
duplicate of a previous
:* Friday, 29 June 2012 3:05 PM
*Subject:* Re: [algogeeks] MS Question: Segregrate positive and negative
nos in array without changing order
duplicate of a previous post.Kindly refer to that post.
Saurabh Singh
B.Tech (Computer Science)
MNNIT
blog:geekinessthecoolway.blogspot.com
On Fri, Jun
*Subject:* Re: [algogeeks] MS Question: Segregrate positive and
negative nos in array without changing order
duplicate of a previous post.Kindly refer to that post.
Saurabh Singh
B.Tech (Computer Science)
MNNIT
blog:geekinessthecoolway.blogspot.com
On Fri, Jun 29, 2012 at 10:41 AM
:05 PM
*Subject:* Re: [algogeeks] MS Question: Segregrate positive and
negative nos in array without changing order
duplicate of a previous post.Kindly refer to that post.
Saurabh Singh
B.Tech (Computer Science)
MNNIT
blog:geekinessthecoolway.blogspot.com
On Fri, Jun 29, 2012 at 10:41
*Subject:* Re: [algogeeks] MS Question: Segregrate positive and
negative nos in array without changing order
duplicate of a previous post.Kindly refer to that post.
Saurabh Singh
B.Tech (Computer Science)
MNNIT
blog:geekinessthecoolway.blogspot.com
On Fri, Jun 29, 2012 at 10:41 AM, raghavan M
23 matches
Mail list logo