•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the C section within the Software Development category of DaniWeb, a massive community of 391,944 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,901 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our C advertiser:
Views: 12901 | Replies: 49
![]() |
•
•
Join Date: Dec 2003
Location: Nashville, TN
Posts: 2,333
Reputation:
Rep Power: 11
Solved Threads: 101
•
•
•
•
Originally Posted by galmca
i have been online here for 2 hrs..almost and didn't get any reply from any1/../so i was checking on some other threads of this site....as im new to this site...so plz don't take it otherwise...and help me out.......plz with this problem......
2 hours?!?!? You've not gotten an answer in 2 hours, and you're complaining?!?!?
Come on now. We're doing this for free-- you have no right to complain even if we don't answer in 2 days! Please be more mindful in the future. If nobody answers your question promptly, it's likely because we don't have the answer, or the right person has not yet visited the site.
Please be more considerate of other forum members, and don't bump your post in the same day you posted.
Alex Cavnar, aka alc6379
>it's likely because we don't have the answer, or the right person has not yet visited the site.
Or the first person who wanted to help was too insulted and deleted the meat of her post.
Anyway, it's best to just ignore people like galmca. They go away after a short time and leave us in peace.
Or the first person who wanted to help was too insulted and deleted the meat of her post.
Anyway, it's best to just ignore people like galmca. They go away after a short time and leave us in peace. Member of: Beautiful Code Club.
•
•
Join Date: Jun 2004
Location: Marin, CA, USA
Posts: 434
Reputation:
Rep Power: 5
Solved Threads: 10
#include <stdio.h>
int main(){int*i,*j,a[]={10,20,30,40,30};for(i=a;i<&a[sizeof a/sizeof*a];++i){for(j=a;j<i;++j){if(*i==*j){break;}}if(i==j){printf(&",%d"[i==a],*i);}}putchar('\n');return 0;}
•
•
Join Date: Dec 2003
Location: Nashville, TN
Posts: 2,333
Reputation:
Rep Power: 11
Solved Threads: 101
•
•
•
•
Originally Posted by Chainsaw
Well, galmca has legitemate questions and supplies some sample code, so s/he just needs to learn a little etiquate. That's better than the people who type in the question the professor posed and wants us to do their homework.
Very true, but I think according to Narue, there's a trend possibly forming...
Alex Cavnar, aka alc6379
•
•
•
•
Originally Posted by Dave Sinkula
#include <stdio.h> int main(){int*i,*j,a[]={10,20,30,40,30};for(i=a;i<&a[sizeof a/sizeof*a];++i){for(j=a;j<i;++j){if(*i==*j){break;}}if(i==j){printf(&",%d"[i==a],*i);}}putchar('\n');return 0;}
#include<stdio.h>
#include<stdlib.h>
a[20]={0};i=0;n=20;d(j)int(j);{j<n?printf("%-3i",
j++[a]),d(j):putchar('\n');}e(j)int(j);{j<20?j++[
a]=rand()%10,e(j):d(0);}f(j){j<n-1?j[a]=a[j+1],f(
j+1):--n;}g(i,v)int(i),v;{return(i>=n?i:i[a]==v?f
(i),g(i,v),i:g(i+1,v),i);}main(){!i?e(0):i==n?d(0
):0;return(i!=n?(i=g(i+1,i[a])),main():0);} Member of: Beautiful Code Club.
•
•
Join Date: Oct 2004
Posts: 47
Reputation:
Rep Power: 4
Solved Threads: 0
im really sorry but i didn't get the code which has been provided to me...it seems really complex when i read that....so could u plz help me out in the terms of the way i wrote....that way i'll be able to understand better...like to find out the duplicate element in an array...
for(i=0;i<5;i++)
{
for(j=0;j<5;j++)
{
if(a[i]==a[j])
printf("duplicate exists");
else
printf("duplicate does not exists");
}
}
for(i=0;i<5;i++)
{
for(j=0;j<5;j++)
{
if(a[i]==a[j])
printf("duplicate exists");
else
printf("duplicate does not exists");
}
}
•
•
Join Date: Oct 2004
Location: Lebanon OR, 97355
Posts: 67
Reputation:
Rep Power: 4
Solved Threads: 0
I think on my part, Narue is a smart person, but does have a short fuse for newbies, i was new, but i found fast how to fit in better, read some other post's, to figure out how things go, some people arn't like me and go to the extent to fit in. galmca does have a good question, since ima newbie, and just learned the loops and what not, idont know how to helpm, Narue, you'r smart, but atleast don't be so rude about it, and yes galmca, i have 2 post'sd that have been here for days and, no answer, so i took matters into my own hands, and did it myself. They arn't paid, so sometimes, do it yourself has to be sufficient..
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
•
•
•
•
•
•
•
•
DaniWeb C Marketplace
Other Threads in the C Forum
- Previous Thread: Help with strings and file directory tree
- Next Thread: Fatal Error C010?



Linear Mode