AmitDiwan has Published 10744 Articles

Python Program to Reverse a Stack using Recursion

AmitDiwan

AmitDiwan

Updated on 15-Apr-2021 12:44:34

658 Views

When it is required to reverse a stack data structure using recursion, a ‘stack_reverse’ method, in addition to methods to add value, delete value, and print the elements of the stack are defined.Below is a demonstration of the same −Example Live Democlass Stack_structure:    def __init__(self):       self.items = ... Read More

Python Program to Implement Stack using One Queue

AmitDiwan

AmitDiwan

Updated on 15-Apr-2021 12:43:52

817 Views

When it is required to implement a stack using a single queue, a ‘Stack_structure’ class is required along with a Queue_structure class. Respective methods are defined in these classes to add and delete values from the stack and queue respectively.Below is a demonstration of the same −Example Live Democlass Stack_structure:   ... Read More

Python Program to Select the nth Largest Element from a List in Expected Linear Time

AmitDiwan

AmitDiwan

Updated on 15-Apr-2021 12:39:44

416 Views

When it is required to select the nth largest element from a list in linear time complexity, two methods are required. One method to find the largest element, and another method that divides the list into two parts. This division depends on the ‘i’ value that is given by user. ... Read More

Difference Between Trigger and Procedure

AmitDiwan

AmitDiwan

Updated on 15-Apr-2021 07:48:12

2K+ Views

In this post, we will understand the difference between trigger and a procedure.TriggersIt is implicitly invoked when an event such as INSERT, DELETE, and UPDATE occurs in a table of a database.Nesting of triggers can be achieved using a table.A trigger can’t be called or defined inside another trigger.Transactional statements ... Read More

Difference Between ALTER and UPDATE Command in SQL

AmitDiwan

AmitDiwan

Updated on 15-Apr-2021 07:46:18

3K+ Views

In this post, we will understand the difference between the ALTER command and the UPDATE command in SQL.ALTER CommandThis command is a Data Definition Language (DDL).It performs operation at the structural level, not the data level.This command is used to add, delete, and modify the attributes of the tables in ... Read More

Difference Between ROLAP and MOLAP

AmitDiwan

AmitDiwan

Updated on 15-Apr-2021 07:43:12

3K+ Views

In this post, we will understand the difference between ROLAP and MOLAP.ROLAPIt stands for Relational Online Analytical Processing.It is used for large volumes of data.The access time in ROLAP is slow.It stores data in the form of relation tables.The data in ROLAP is fetched from a data warehouse.It uses complex ... Read More

Difference Between Strong and Weak Entity

AmitDiwan

AmitDiwan

Updated on 15-Apr-2021 07:40:52

358 Views

In this post, we will understand the difference between strong entity and weak entity −Strong EntityIt has primary key.It doesn’t depend on any other entity.It can be represented using a single rectangle.The relationship between two strong entities can be represented using a single diamond.It can either have total participation or ... Read More

Difference Between View and Materialized View

AmitDiwan

AmitDiwan

Updated on 15-Apr-2021 07:37:31

2K+ Views

In this post, we will understand the difference between a view and a materialized view.ViewsIt is a logical and virtual copy of a table that is created by executing a ‘select query’ statement.This result isn’t stored anywhere on the disk.Hence, every time, a query needs to be executed when certain ... Read More

Difference Between Star and Snowflake Schema

AmitDiwan

AmitDiwan

Updated on 15-Apr-2021 07:35:33

376 Views

In this post, we will understand the difference between star schema and snowflake schema.Star SchemaHierarchies of dimensions are stored in a dimensional table.It contains a fact table that is surrounded by dimension tables.In this schema, a single join creates the relationship between a fact table and any dimension tables.It is ... Read More

Python Program to Select the nth Smallest Element from a List in Expected Linear Time

AmitDiwan

AmitDiwan

Updated on 14-Apr-2021 14:19:28

476 Views

When it is required to select the nth smallest element from a list in linear time complexity, two methods are required. One method to find the smallest element, and another method that divides the list into two parts. This division depends on the ‘i’ value that is given by user. ... Read More

Advertisements