ParsX.com
پذیرش پروژه از دانشجویی ... تا سازمانی 09376225339
 
   ProfileProfile   Log in to check your private messagesLog in to check your private messages  |  FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups Log inLog in   RegisterRegister 

این 3 تا را کی می تواند جواب بده؟

 
Post new topic   Reply to topic    ParsX.com Forum Index -> اصول ساختمان داده ها
View previous topic :: View next topic  
Author Message
#ASAL#
مهمون يكي دو روزه


Joined: 06 Jan 2006
Posts: 1
Location: tehran

PostPosted: Fri Jan 06, 2006 1:08 pm    Post subject: این 3 تا را کی می تواند جواب بده؟ Reply with quote

سلام Smile
من 3 تا سوال دارم که نهایتا تا 23/10 جواب آن را به c میخواهم:
1.درخت را با ارایه پیاده سازی کنید.
2.برنامه ای بنویسید که عمل یک صف را پیاده سازی کنید.
3.شبه کد های لازم برای تغییر جهت یک لیست پیوندی یک جهته را بنویسید.
ممنون می شم اگر زود جواب بگیرم چون امتحان دارم Wink
Back to top
vahid
بي تو هرگز


Joined: 26 Nov 2004
Posts: 3067
Location: Tehran

PostPosted: Fri Jan 06, 2006 1:40 pm    Post subject: Reply with quote

اخه الان همه امتحان دارن .
جواب اولين سوالت رو ميدم ...
Back to top
arash
مدير بخش سي
مدير بخش سي


Joined: 27 Nov 2004
Posts: 1232
Location: www.parsx.com

PostPosted: Fri May 26, 2006 10:59 pm    Post subject: Reply with quote

می خواهم حلش کنم
با چه برنامه ای بهتره
فکر کنم پیش فرض پاسکاله
Back to top
vahid
بي تو هرگز


Joined: 26 Nov 2004
Posts: 3067
Location: Tehran

PostPosted: Sat May 27, 2006 12:55 pm    Post subject: Reply with quote

شما حلش كن . با هر چي كه خواستي ...
Back to top
arash
مدير بخش سي
مدير بخش سي


Joined: 27 Nov 2004
Posts: 1232
Location: www.parsx.com

PostPosted: Mon May 29, 2006 3:42 pm    Post subject: Reply with quote

در دیزی بازه ...

حالا ما یه چیزی گفتیم ...
Back to top
elinaz
مهمون يكي دو روزه


Joined: 21 Nov 2007
Posts: 42
Location: تهران

PostPosted: Thu Nov 22, 2007 1:43 pm    Post subject: Reply with quote

دوست عزيز
در مورد جواب سوال دومتون من قبلا يك برنامه نوشتم كه تعدادي خطا داره (خيلي كم) – ولي فكر كنم بتونه تا حدودي كمكت كنه

اين يك برنامه است كه اسامي تعدادي از افراد را از ورودي خوانده و در صف قرار مي دهد. اين برنامه عناصر را از صف خارج و اسامي موجود در صف ر ا نمايش مي دهد


# include <stdio.h>
# include <stlib.h>
#define MAX 100
char *p[MAX];
int spos,rpos;
void enter(void);
void review(void);
void delete(void);
char *qretrive();
char ch;

Main()
{
]; char s[80
register int t;
( ++ for(t=0;t<MAX;t
; p[t]=NULL
; spos=0
; rpos=0
) while(1
{
Clrscr();

); gotoxy(20,4
"); printf(" E) enter name to queue
); gotoxy(20,6
"); printf(" R) remove name from queue
); gotoxy(20,8
"); printf(" L) list the queue
); gotoxy(20,10
"); printf(" Q) quit from program
); gotoxy(20,12
"); printf(" enter your select
); gotoxy(20,6
; )") : printf(" (E R L Q
; ( gets(s
); *s=toupper(*s
) switch (*s
{
': case 'E
(); enter
; break
': case 'L
Review();
ch=getch()
; break
': case 'R
(); delete
; break
': case 'Q
); exit(0
{
{
{

() void enter
{
; char s[256],*p
}do
"); printf("\n enter a name
Smile "); printf("(ENTER for none
; ( gets(s
) if (*s==0
; break
)); p=malloc(strlen(s
( if (!p
}
"); printf("\n out of memory
; return
{
); strcpy(p,s
( if(*s
; ( qstore(p
); while(*s{

{

() void review
}
; register int t
) ++ for (t=rpos;t<spos;t
]); printf("\n\t%d . %s",t+1,p[t
}

() void delete
{
; char *p
())) if (!(p=qretrive
; return
; ( printf("\n $s",p
}
) void qstore (char *q
{
) if(spos==MAX
{
); ". printf("\n list is full
(); ch=getch
; return
}
; p[spos]=q
++; spos
}
() char *qretrive
{
( if(rpos==spos
}
."); printf("\n the list is empty
(); ch=getch
; return NULL
}
++; rpos
]; return p[rpos-1
}



-----------------------
صدها نفر براي بارش باران دعا كردند
غافل از آنكه خدا با كودكي است كه چكمه هايش سوراخ است
Back to top
elinaz
مهمون يكي دو روزه


Joined: 21 Nov 2007
Posts: 42
Location: تهران

PostPosted: Thu Nov 22, 2007 1:45 pm    Post subject: Reply with quote

لطفا علامتهايي كه در برنامه جابه جا شده خودت درست وارد كن
Back to top
Display posts from previous:   
Post new topic   Reply to topic    ParsX.com Forum Index -> اصول ساختمان داده ها All times are GMT + 3.5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum