No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
- Interests
- Programming........
- PC Specs
- Windows 7 ultimate
[CODE]#include<stdio.h> #include<conio.h> main() { typedef enum y; int c; y colour {RED,WHITE,BLUE,BLACK}; clrscr(); printf("The assigned value is %d\n",RED); printf("The assigned value is %d\n",BLUE); printf("The assigned value is %d\n",BLACK); c=RED+BLACK; printf("RED+BLACK IS %d",c); getch(); }[/CODE] What is wrong with this code please? |
|
Could we find the largest among three numbers using 'for' and if? I have the following program, please check it #include<stdio.h> main() { int a,b,c,sum=o,i'; printf("enter the numbers"); scanf("%d%d%d",&a,&b,&c); sum=a+b+c; for(i=sum;i<=sum,i--) { if(i==a||i==b||i==c) printf("%d the greatest"); exit(); }}........please clarify the logic if it is correct to the intention.. |
|
Re:
Hmm I was lookin through a recursion program in this book i have here and the only thing I'm having trouble with is the modulus operator. I know that it returns the remainder of 2 numbers. But, suppose I have this: x % y If x > y then the … |
|
I have a statement in c as 3*3*3%4 and the output is 3 how is that? |