Tuesday, February 04, 2020

CPP: Using std::list

Very basic usage of C++ STL std::list
#include<iostream>
#include<list>
int main()
{
std::list<int> int_list {1,2,3,4,5};
for(int i: int_list)
{
std::cout << i << std::endl;
}
return 0;
}
view raw stdlist.cpp hosted with ❤ by GitHub


To build:
$: clang++ stdlist.cpp

Run it:
$: ./a.out

No comments:

Running QNX on emulated cortex-a15 using QEMU

Running QNX on emulated cortex-a15 using QEMU General information: - Host (for running QEMU) OS: Ubuntu 24.04.2 LTS - QEMU: QEMU emulator...