What is a data structure? Provide examples.
What is a data structure? Provide examples.
A data structure is a way of organizing and storing data to enable efficient access and modification. The choice of data structure affects the efficiency and performance of algorithms. Common examples include arrays, linked lists, stacks, queues, trees, graphs, and heaps. Each type of data structure is suited for different types of operations and use cases, allowing for optimized performance in various scenarios.