top of page
Writer's pictureRosario Riley

Why we need different data types in programming?

In computer science, a data structure is a particular way of collecting and forming data in computer in such away so that we can operate on them efficiently. Every enterprise application uses various types of data structures in one or the other way.


Computer programs are composed of two items: Data and Operations on that Data. Because, at their heart, computers are simple devices, they can only represent very simple pieces of information.





The data types can simply be described as: int, booleans, characters, arrays, structures and so on.


In simple language, we can describe Data Structures are structures programmed to store data, ordered data, so that we can perform different operations easily. It represents the knowledge of data to be organized in memory occupation.


For example if we store data as name “Mira” and Percentage “75.5”, then record data name is string type and percentage is float type. Record stored is student name with percentage. We can also store with Roll-No (Integer).



Integral Types


Ø Integral data types include all whole numbers, that is numbers they don’t have any fractional component itself.

Floating Point Types

Ø Floating point types include all types in which a number may have a fractional component, such as 3.14 or pi.

Characters

Ø Most modern computer programming languages store alphabets, characters by representing each one using a small piece of numeric code.

Ø As we know that number of characters that must be stored is typically a large number, and the number of bits needed to represent each character by character which is unique and small.

Strings


Ø Most modern computer programming languages have means of representing character strings, which is collections of characters such as words or sentences etc. to performed the manipulation operation on different data as per usage.

Arrays


Ø Arrays which are collections of data elements all having the same data type, so the execution becomes easy performing some operation on index value.

Classes


Ø Classes are also similar like structures, except that in addition to data, they also contain the functions (methods) which is associated with the data.

Ø The classes which is a collection of related data that represents an entity also represents methods to maintain and manipulate that data as per requirement.


TCCI provides best teaching in various programming courses through different learning method/media as student’s convenience.


For More Information:

Call us @ 9825618292

Visit us @ http://tccicomputercoaching.com

Recent Posts

See All

Comments


bottom of page