Type Casting: Assume the following declarations: Rewrite those of the following statements which would generate a compile-

Question:

Type Casting: Assume the following declarations:

int integer; double precise Real; float sloppy Real; long bigInteger;

  1. Rewrite those of the following statements which would generate a compile- time error using an appropriate cast that makes the error go away. Do not provide a cast for any statement which the compiler automatically promotes.
  2. integer preciseReal; sloppy Real = integer; bigInteger = sloppy Real; precise Real = bigInteger; bigInteger;
Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Question Posted: