हिंदी

Give reason whether the following assignment is correct or not. float f = 0.002654132; - Computer Applications

Advertisements
Advertisements

प्रश्न

Give reason whether the following assignment is correct or not.

float f = 0.002654132;

संक्षेप में उत्तर

उत्तर

This assignment is incorrect since the data type for 0.002654132 is double, yet it is assigned to a float variable. The correct assignment will be float f = 0.002654132f;

shaalaa.com
  क्या इस प्रश्न या उत्तर में कोई त्रुटि है?
अध्याय 1.03: Values and Data Types - EXERCISES [पृष्ठ ३३]

APPEARS IN

अविचल Computer Applications [English] Class 10 ICSE
अध्याय 1.03 Values and Data Types
EXERCISES | Q III. 12. (b) | पृष्ठ ३३
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×