manoj... you just did someone's homework. I'd hope they'd be satisfied.
I've came to an idea.
Maybe, if we do their homework for them and add in some odd errors to dock them 
points, they'll do it themselves, after the first c/d or what ever. <cackle>


Thanks,
Tyler Littlefield
email: [EMAIL PROTECTED]
web: tysdomain-com
Visit for quality software and web design.
skype: st8amnd2005

  ----- Original Message ----- 
  From: Manoj Vivek 
  To: [EMAIL PROTECTED] 
  Cc: [email protected] 
  Sent: Saturday, November 08, 2008 5:53 AM
  Subject: RE: [c-prog] finding odd element..


  this can be solved as follows.....
  if you consider that the 2n+1 is 11 them we can do the program as follows

  main()
  {
  int a[11],i,j,ans;
  for(i=0;i&lt;11;i++)
  scanf(&quot;%d&quot;,&a[i]);
  for(i=0;i&lt;11;i++)
  {
  for(j=0;j&lt;11;j++)
  {
  if(i==j)
  continue;
  if(a[i]==a[j]
  continue;
  else
  ans=a[j]; 
  }
  }
  printf(&quot;%d&quot;,ans);
  }
  satisfied???

  una_020 wrote: 
  > given an array of 2n+1 elemnts n of the elemnts having duplicates how 
  > do u find the number wihout having duplicate..? ? 
  > 



   

[Non-text portions of this message have been removed]

Reply via email to