203k views
4 votes
What is the difference in the way computers store numeric data and non-numeric data?

1 Answer

4 votes
Both numeric and non-numeric data have different ASCII codes, that will be the first difference. Second, numeric data are stored in float, double, and int variables while non-numeric data are stored in char. However, both can be stored in a String variable if and only if the desired data to be stored will not be used for computuation using mathematical operations such as addition.

To store a non-numeric data in an array, the array must first be declared as a String variable array while a numeric data can be stored in an array once the array which will store the numeric data is declared as an integer, double, or float variable.
User XtrmJosh
by
8.1k points