- Upvotes Received
- 0
- Posts with Upvotes
- 0
- Upvoting Members
- 0
- Downvotes Received
- 2
- Posts with Downvotes
- 2
- Downvoting Members
- 2
15 Posted Topics
Re: i guess u can try some recursive algorithm for this .but with that 0(n) is still tough .. with recursive u can try maximum combinations while keeping efficiency .. | |
hi ... i want to use php 4 and apache 2 on fedora core 4 ... butr not been able to use ... so can anyone tell me how to plugin php non apache on linux platform .... Ashish | |
hi ... can anyone please tell what are Lvalue and Rvalue errors in c and c++ ??? | |
hi .. can anyone help me to understand what are the uses of different OOPS concepts of c++ and how thse features helps in programming in c++ ... specailly features like data abstraction etc ... | |
| |
int i=0,j=1; cout<<(j++)&&(i++); //output=1; i=0,j=1; printf("%d",(j++)&&(i++)); //output=0 can anyone please tell why this difference in output ??? | |
char s[]="the cocaine man"; int i=0; char ch; ch=s[++i]; printf("%c ",ch); ch=s[i++]; printf("%c ",ch); ch=i++[s]; printf("%c ",ch); ch=++i[s]; printf("%c ",ch); output = h h e ! i got the outputs like this ...can anyone please what are the reasons for these outputs !! is it compiler dependent ?? if yes … | |
if i implement same algorithm iteratively and also with recusrion ...than which of the above methods is better in implementing ..... and what are the advantages of recursion over iterative methods ?? | |
can anyone tell me what are pointers to function ??? and how are they implemented ?? | |
given a positive integer n ,we have to find the number of possible combination of integers (i,j) where i+j=k ... given 0<=i,j,k<=n i code this problem as below ... [code]#include<iostream.h> #include<conio.h> void max(int n,int x,int k,int *no) { if(x>=0) { max(n,x-1,k,no); if(n+x==k) { (*no)+=1; cout<<"\n"<<" The combinations are formed by … | |
can anyone tell me the code for inorder traversal of binary tree non recursively and using a constant memory ...?? | |
can anyone explain me why the values are not swapped in the below code ?? main() { int *i,*j; *i=4000; *j=9000; f(i,j); printf(" %d %d",*i,*j); //output =4000 9000 } void f( int *a, int *b) { int *temp; temp=a; a=b; b=temp; } | |
Re: [quote=TJW]Why is the last element not 7 [code] int array[3]; int *ary; ary=array; array[0]=0; array[1]=0; array[2]=0; array[3]=44; for (int i=0;i<4;i++) { cout<<array[i]; } cout<<endl; *(ary+0)=1; *(ary+1)=0; *(ary+2)=0; *(ary+3)=7; for (int i=0;i<4;i++) { cout<<array[i]; } cout<<endl; [/code] Output 00044 1003<-----------------Why 3 and not 7!!!!!![/quote] hey ..d ans is very simple d … | |
can anyone please tell me why following output is generated ... int i=10; printf(" %d ",i++/i); // output=0 i=10; printf("%d",i/++i); //output=1 i=10; printf("%d ",i++/++i); //output =0 i=10; printf("%d",++i/i); //output=1 | |
hi .. if anyone cn plz tell me wht will be the output of following code n how dis output is generated ... float i=10; printf("i++/i %f\n",i++/i); printf("%f \n",i); i=10; printf("i/++i %f \n",i/++i); printf("%f \n",i); i=10; printf("i++/++i %f \n",i++/++i); printf("%f \n",i); i=10; printf("++i/i %f \n",++i/i); printf("%f \n",i); |
The End.