one more problem is there
int main()
{
short int a,b,c;
scanf("%d",&a);
sacnf("%d",&b);
c=a+b;
printf("c=%d",c);
return(0);
}
if a=30,b=40,
then c=40;
and if a=40,b=30,
then c=30;
why it is ?
eplain in details


On Tue, Oct 12, 2010 at 2:55 AM, carry <[email protected]> wrote:

> int main()
> {
> int i;
> char c;
> for(i=0;i<5;i++)
> {
> scanf("%d",&c);
> printf("%d",c);
> }
> }
> why the program scans only one time if u give an alphabet as an
> input??
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<algogeeks%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.

Reply via email to