unsigned int a = 6 E unsigned int b = 1 int c = a long d = unsigned long e = (Assume ints are 3 wide.) unsigned unsigned

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter5: Control Structures Ii (repetition)
Section: Chapter Questions
Problem 28SA
icon
Related questions
Question
V.
After executing the following code, which of the variables are equal to 0?
unsigned int a = 0xffffffff;
unsigned int b = 1;
unsigned int c = a + b;
unsigned long d = a + b;
unsigned long e = (unsigned long) a + b;
(Assume ints are 32 bits wide and longs are 64 bits
wide.)
(a) None of them
(b) c
(c) c and d
(d) c, d, and e
Transcribed Image Text:V. After executing the following code, which of the variables are equal to 0? unsigned int a = 0xffffffff; unsigned int b = 1; unsigned int c = a + b; unsigned long d = a + b; unsigned long e = (unsigned long) a + b; (Assume ints are 32 bits wide and longs are 64 bits wide.) (a) None of them (b) c (c) c and d (d) c, d, and e
Expert Solution
steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Knowledge Booster
Mathematical functions
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning