Posts
 
Reputation
Joined
Last Seen
Strength to Increase Rep
+0
Strength to Decrease Rep
-0
0% Quality Score
Upvotes Received
0
Posts with Upvotes
0
Upvoting Members
0
Downvotes Received
3
Posts with Downvotes
2
Downvoting Members
3
1 Commented Post
0 Endorsements
Ranked #31.8K
Ranked #4K
~838 People Reached
Favorite Forums
Favorite Tags

5 Posted Topics

Member Avatar for harshchandra

/* Non-recursive Permutation generator By : Mudit Aggarwal */ #include<stdio.h> #include<string.h> void main() { /* String */ char ch[]="123"; char temp; int len = strlen(ch), count=1; int i, start=len-2, end=len-1; // Finds permutation count for(i=1; i<=len; i++) count *= i; for(i=0; i<count; i++) { //swap characters temp=ch[end]; ch[end]=ch[start]; ch[start]=temp; printf("%s\n",ch); …

Member Avatar for Nick Evan
-2
275
Member Avatar for no4touchy

for (llint i = 0;i != labs (diff) + 1; ){ or llint diff = labs (start < end ? start - end : (start == end ? 1 : end - start)), *genList = calloc (diff, sizeof (llint)); for (llint i = 0;i != diff + 1; ){ In …

Member Avatar for no4touchy
0
123
Member Avatar for SIFA

try compiling this code and u can figure out the solution from the error. use character pointer for return. Instead of using char iResult ..use char array and return that. For loop should work properly.

Member Avatar for Ancient Dragon
0
144
Member Avatar for girishn
Member Avatar for yasokrish

The above problem is an example of buffer overflow ( stack overflow) fread tries to store data in a buffer outside the memory the programmer set aside for it (12 bytes) Also it is a good practice to validate the file pointer after opening the file. You should check badfile …

Member Avatar for muditAggarwal
0
170

The End.