Search found 7 matches

by ashish_thakur
Sun Dec 28, 2008 10:24 am
Forum: Volume 100 (10000-10099)
Topic: 10000 - Longest Paths
Replies: 160
Views: 36709

Re: 10000 - Longest Path

Ok I got it return 0 was missing in main
by ashish_thakur
Sat Dec 27, 2008 8:45 pm
Forum: Volume 100 (10000-10099)
Topic: 10000 - Longest Paths
Replies: 160
Views: 36709

Re: 10000 - Longest Path

Hello I tried but I am geting RE with the modified changes please help me out #include<stdio.h> #include<stdlib.h> #include<string.h> struct node{ int value; struct node * next; }; int numNodes; int largestDepth; void VISIT(struct node **Node, int n,int *visit,int *f){ struct node *NODE = Node[n]; i...
by ashish_thakur
Wed Dec 24, 2008 6:11 pm
Forum: Volume 100 (10000-10099)
Topic: 10000 - Longest Paths
Replies: 160
Views: 36709

Re: 10000 - Longest Path

here is the code with TL error #include<stdio.h> #include<stdlib.h> struct node{ int value; struct node * next; }; int numNodes; int largestDepth; VISIT(struct node **Node, int n){ static int depth=0; struct node *NODE = Node[n]; while(NODE!=0){ ++depth; VISIT(Node,NODE->value); NODE=NODE->next; } i...
by ashish_thakur
Wed Dec 24, 2008 11:30 am
Forum: Volume 100 (10000-10099)
Topic: 10000 - Longest Paths
Replies: 160
Views: 36709

Re: 10000 - Longest Path

Thanks , Now I am getting TL error is there any standard algo for this type of problem
by ashish_thakur
Wed Dec 24, 2008 1:01 am
Forum: Volume 100 (10000-10099)
Topic: 10000 - Longest Paths
Replies: 160
Views: 36709

Re: 10000 - Longest Path

I am getting Runtime error please help #include<stdio.h> #include<stdlib.h> struct node{ int value; struct node * next; }; int numNodes; int largestDepth; VISIT(struct node **Node, int n){ static int depth=0; struct node *NODE = Node[n]; while(NODE!=0){ ++depth; VISIT(Node,NODE->value); NODE=NODE->n...
by ashish_thakur
Tue Dec 23, 2008 6:09 pm
Forum: Volume 104 (10400-10499)
Topic: 10405 - Longest Common Subsequence
Replies: 103
Views: 29535

Re: 10405 - Longest Common Subsequence

thanks for the insight I have corrected the flaw. It's accepted
by ashish_thakur
Mon Dec 22, 2008 9:55 pm
Forum: Volume 104 (10400-10499)
Topic: 10405 - Longest Common Subsequence
Replies: 103
Views: 29535

Re: 10405 - Longest Common Subsequence

Why is it giving run time error please help? #include <string.h> #include <stdio.h> int LCSlength(char *seq1, char *seq2){ int len1 = strlen(seq1); int len2 = strlen(seq2); if(!(len1 && len2)) return 0; int C[len1][len2]; int i=0,j=0; int cond=0; for(;i<len2;i++) if(!cond) cond=C[0] =(seq1[0]==seq2 ...

Go to advanced search