Find the fallacy in the following program segment?

int a;
short b;
b=a;

Answer Posted / aman

b=a; is the error line.
possible high value of a can cause an error in b.
data value will go out of limit.
range of int is more than short type.

Is This Answer Correct ?    8 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to freely move a ball in graphics mode.

1902


what is the stucture of.net array?

1608


Do you have any tips for using 3G phones?

1438


I have got one problem .I initially have got windows vista in my computer but now I installed linux UBUNTU operating system into my computer .For this i first format D: drive and got installed finely there and restart , when it boots there there were two options vista and ubuntu .But the problem is that when i choose vista it opens but screen seems to be dark only mouse pointer sees in the screen and no more windows appeared . But when i choose ubuntu it opens and asks for username and password .But i don't know these things. But linux is freeopen software , why it asks userename and password ? Now i am unable to use my computer ,i installed lunux without partioning the drive. Plz give me the solution The computer configuration of my computer is 80 GB harddisk, 1 GB RAM.3GHz speed.

1407


What is the allowable load carrying capacity of a circular column section of 400 mm diameter reinforced with 6x25 mm diameter bars adequately tied with spirals? Consider concrete of grade M25 and steel of grade Fe 415.

1627






explain various object oriented programming fetures

1328


how to reuse an outdated laptop?

1577


what size shaft is required to transmit 100 hp @1000 RPM ,if max shear stress is 10,000 PSI,angle of twist must be less than 1' /ft/shaft is made of steel.

1489


What is the instruction to load the register B?

1848


what is the use of typedef in c language?

1556


what are all the browsers..?

1449


why does the array will be start on size 0?

1585


A rectangular sheet dimensions a x b is to be made into an open-topped box by cutting a square of side h from each corner and folding the 4 sides up. Find the value of h which allows the maximum volume of the box?

731


how convert the spiral model to prototype model ?

1266


how many protocols are available and what are they?

1875