answersLogoWhite

0


Best Answer

By basic types you presumably mean primitive types or built-in types. These include char, int, long, short, wchar_t, float, double and bool, amongst others. Most are simply variations of each other, but their lengths are implementation dependant. The only exception is char which is always 1 byte in length.

User-defined types are those you yourself define or are defined for you. These include typedefs, enums, classes, structs and unions, but can also include some implementation-specific built-in types and all third-party types. Regardless, all user-defined types build upon the primitive data types or other user-defined types. In the case of class and struct types, methods (or member functions) can be associated with those types, thus combining data and the specific methods that act upon that data into a single entity. Objects are specific instances of a class or struct.

A derived type is a class (or struct) which inherits from another class (or struct). A derivative cannot inherit from a primitive, enum or union. Derived types are also, by definition, user-defined types.

User Avatar

Wiki User

10y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is the difference between basic data types and derived data types and user defined data types in C plus plus?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

What is the difference between visual basic and visual c?

The programming language: Visual Basic is a BASIC-like (or BASIC-derived) language, Visual C is... well C.


What is the difference between elementary level and basic level?

what is the difference between elementary and basic


What is the basic difference between fillet and radius?

no difference


What are the difference between Basic Salary and Net pay?

can u pls give me the difference between basic and net pay


What is difference between basic command and statement?

difference between command and statement


What is the basic difference between C?

Nothing.


Difference between pascal and basic?

Kgd


What is the basic difference between speech and written communication?

Speech communication involves the verbal exchange of information through spoken words, while written communication conveys messages through written text. Speech is immediate and allows for real-time interaction, while written communication offers a permanent record that can be referenced later. Both forms have their own strengths and weaknesses in terms of clarity, tone, and audience engagement.


What is the difference between applied research and action research?

Applied research focuses on solving practical problems through the application of existing knowledge and theories, while action research involves engaging stakeholders in identifying issues, taking action, and reflecting on the outcomes to drive change and improvement. Action research is more collaborative, participatory, and iterative compared to applied research.


What is the difference between basic earning per share and adjusted earning per share?

what is the difference between basic earning per and adjusted earning per share?


What is the difference between bat and owl?

The basic difference between bats and owls is that bats are mammals and owls are birds.


What is the basic difference between Duel Core Processer and Core 2 Deu Processer?

What is the basic difference between Duel Core Processer and Core 2 Deu Processer?