I'm looking forward to the next lecture from STL, anyone know when it might be.
Charles do you know?
Comments
-
-
Happy Christmas to you Stephen,
Bring on more C++ videos.
Keep up the good work, an excellent Christmas present from C9 team.
Thanks again
-
Hey STL,
Any Idea when User Defined Literals will be implemented in VC2012, i'm looking forward to trying something like,
int operator "" _MB (unsigned long long) {return 1024;} int main(void) { int mySize = 34_MB; printf("%d",mySize); return 0; }Tom
-
Hey STL,
I managed to write the Linked List using unique_ptrs finally, it was me who emailed you!
Took me a fair while though.
Here's my code.#include <memory> #include <utility> using namespace std; template <typename T> struct Node{ T data; unique_ptr<Node<T>> next; public: Node(T val):data(val),next(nullptr){} Node(T val,unique_ptr<Node>&& next){ this->next = move(next); } Node(T val,unique_ptr<Node>& next){ this->data = val; this->next.swap(new Node<T>(next->data)); } void insertAfter(T& data){ next = unique_ptr<Node<T>>(new Node<T>(data,next)); } }; template <typename T> class SList{ private: unique_ptr<Node<T>> head; int size; public: SList(){ size = 0; head = nullptr; } void insertFront(T val){ head = unique_ptr<Node<T>>(new Node<T>(val,head)); size++; } };and the main program
#include <iostream> #include "Node.h" using namespace std; int main(){ SList<int> myList; int f = 3; int s = 4; myList.insertFront(f); myList.insertFront(s); return 0; }
Keep up the good work
Tom -
I know, i saw them
I meant an Advanced lecture on Linked Lists and Maps.
How they work etc, but like I said Stephen, it doesn't matter anymore :-> -
Hi,
One topic I'd like to see is see an Advanced Series on Data Structures.
For Example, Linked Lists and Maps.
[edit] Forget that
I can look up data structures on you tube 
As always a great series

Keep up the good workTom
-
Great
another C++ video from Stephen.
Template Specialization,
ive seen a factorial specialization like that.template <int N> struct Factorial { enum { value = N * Factorial<N - 1>::value }; }; template <> struct Factorial<0> { enum { value = 1 }; }; // Factorial<4>::value == 24 // Factorial<0>::value == 1 const int x = Factorial<4>::value; // == 24 const int y = Factorial<0>::value; // == 1Cant wait for part 5, and a meta programming tutorial will be fantastic
-
Hi STL,
I'm programming a directory iterator and I'm getting a error message, but not from my program, from the filesystem header; saying " '_Ptr' : is not a member of 'std::tr2::sys::basic_directory_entry<_Path>'.
my call to path issys::path fullpath = sys::system_complete(sys::path(argv[1]));
Thanks in advance for any assistanceTom
-
Great Video again!
Charles, any idea when the next video will be uploaded?
-
Wow, i must be honoured to get a reply from the man himself.
Thanks for the heads up Bjarne, C++ is really moving up.
So I can just pass a object by value by using rvalue references.
That is soo cool.Tom