Pages

Showing posts with label Python - Core DataTypes. Show all posts
Showing posts with label Python - Core DataTypes. Show all posts

Sunday, July 28, 2024

Python : DataTypes : Core Data Types

Python Core Data Types

It refers to Python's built in Object Types, it comes with python installation.

These are listed as below:

  1. Numbers --> (integer, float, complex numbers, rational fractions with Numerator and Denominator)
  2. Strings
  3. List
  4. Dictionaries
  5. Tuples
  6. Files
  7. Sets
  8. Other Core Types (Eg. Boolean, Types, None)
  9. Program Unit Types (Eg. Funcitons, Classses, modules)
  10. Implementation Related Types (Eg. Compiled Code, Stack Tracebacks)

The above listed Object types would be covered subsequently.

Reasons why we should use Python Built-In types : 
  • Built-in objects make programs easy to write. --- you can use them immediately. You can get a lot of work done with Python’s builtin object types alone.
  • Built-in objects are components of extensions.
  • Built-in objects are often more efficient than custom data structures.



Python : About : Variables

  Variables in Python Variables are used to: Name an object. Remind us about the usability of an object. Allow us to reuse same object in mu...