"A data type is an abstract concept defined by a set of logical properties." - What does that mean?

Asked

Viewed 74 times

1

I’m reading the book "Data Structures Using C", and one of the things the book explains is that a set of bits has no intrinsic meaning, and that the meaning of a given set of bits is given to this set from the way it is interpreted, thus the same set of bits can be interpreted as integers, floating point numbers, or characters. At least that’s what I understood.

Later the book explains that when declaring a variable in a language as C, for example, the type of that variable is used by the compiler to instruct the machine on how to interpret the bits stored in the memory address allocated by that variable.

What confused me is when the author states that we can see the concept of "data types" in a different way, not in terms of what the computer can do, but what the user wants done, and that once the concept of data type is distanced from hardware capabilities the types of data that can be considered are unlimited.

This is where the statement "A data type is an abstract concept defined by a set of logical properties".

What is the meaning of this statement? So far I have not been able to absorb this concept.

Soon after this part follows: "Once such an Abstract data type is defined and the legal Operations involving that type are specified, we may implement that data type (or a close approximation to it)".

  • Which statement you refer to 1st or 2nd ?

  • @Magichat The first.

1 answer

1

He means that a type of data is defined by the rules we set for it during its implementation.

It is a structure with predefined rules - in the implementation - for which data can be stored in it or not.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.