Why doesn't the code "int a = 1000, b = 1000;
long int c = a * b;" work?
Answer Posted / larry
This won't work if int is a 16-bit size because 1000000 >
32767 (2 to the 15th - 1). It will work when int is a 32-
bit number. It will work if you cast a or b to a long.
| Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
p*=(++q)++*--p when p=q=1 while(q<=6)
Write a Program to accept different goods with the number, price and date of purchase and display them
How to draw the flowchart for structure programs?
Give me the code of in-order recursive and non-recursive.
Explain how can a program be made to print the line number where an error occurs?
Can we use visual studio for c?
What is variables in c?
What is file in c language?
What is c variable?
What are pointers really good for, anyway?
What is difference between array and pointer in c?
how many errors in c explain deply
How can you call a function, given its name as a string?
Differentiate between static and dynamic modeling.
What are the types of operators in c?