STARTING OUT WITH C++ REVEL >IA<
STARTING OUT WITH C++ REVEL >IA<
9th Edition
ISBN: 9780135853115
Author: GADDIS
Publisher: PEARSON
Question
Book Icon
Chapter 18, Problem 25RQE
Program Plan Intro

Standard Template Library (STL) list container:

The STL includes the collection of data types and algorithms which can be used by the programmer in their programs.

The STL “list” container is a template version of “doubly” linked list. The elements of the container can iterate either forward or backward. It can grow at either front or back of the list.

The header file named “#include<list>” is used to implement the list container in a program.

Syntax:

Syntax to reverse the order of “STL list” container is as follows:

variable_name.reverse();

  • “variable_name” is the name of the list which is defined by user.
  • “reverse()” is a method to reverse the order of elements in the container.

Blurred answer
Students have asked these similar questions
Write the code that would create a list of data.  The list should be called data.  The data list should be initialized to the following values: 54, 26, 14, 93, 17, -10, 77, 31, 40, 55, 20
A list that contains no data elements is said to be __________.
Write a statement that creates a two-dimensional list with 5 rows and 3 columns. Then writenested loops that get an integer value from the user for each element in the list.
Knowledge Booster
Background pattern image
Similar questions
SEE MORE QUESTIONS
Recommended textbooks for you
Text book image
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Text book image
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Text book image
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
Text book image
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Text book image
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Text book image
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education