Back to Profile: Tominator2005


  • Design Patterns: Decorator

    Hi, I'd quite like to see the Visitor pattern done.

  • Stephan T. Lavavej - Core C++, 8 of n

    I'm looking forward to the next lecture from STL, anyone know when it might be.
    Charles do you know?

  • Stephan T. Lavavej - Core C++, 7 of n

    Happy Christmas to you Stephen,
    Bring on more C++ videos.
    Keep up the good work, an excellent Christmas present from C9 team.
    Thanks again Big Smile

  • Stephan T. Lavavej - Core C++, 6 of n

    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;
      return 0;


  • Stephan T. Lavavej - Core C++, 6 of n

    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;
        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{
        unique_ptr<Node<T>> head;
        int size;
            size = 0;
            head = nullptr;
        void insertFront(T val){
                head = unique_ptr<Node<T>>(new Node<T>(val,head));

    and the main program

    #include <iostream>
    #include "Node.h"
    using namespace std;
    int main(){
        SList<int> myList;
        int f = 3;
        int s = 4;
        return 0;

    Keep up the good work Smiley

  • Stephan T. Lavavej - Core C++, 6 of n

    I know, i saw them Smiley I meant an Advanced lecture on Linked Lists and Maps.
    How they work etc, but like I said Stephen, it doesn't matter anymore :->

  • Stephan T. Lavavej - Core C++, 6 of n


    One topic I'd like to see is see an Advanced Series on Data Structures.
    For Example, Linked Lists and Maps. 
    [edit] Forget that Smiley I can look up data structures on you tube Smiley

    As always a great series Smiley

    Keep up the good work


  • Stephan T. Lavavej - Core C++, 5 of n

    Great Big Smile 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; // == 1

    Cant wait for part 5, and a meta programming tutorial will be fantastic

  • Stephan T. Lavavej - Core C++, 4 of n

    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 is

    sys::path fullpath = 

    Thanks in advance for any assistance


  • Stephan T. Lavavej - Core C++, 4 of n

    Great Video again!

    Charles, any idea when the next video will be uploaded? Smiley

  • Day 1 Keynote - Bjarne Stroustrup: C++11 Style

    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.


  • Day 1 Keynote - Bjarne Stroustrup: C++11 Style

    I've just run a test, and you can scope a variable like in Java now ^_^

    it would be like this

    void f(int n, int x){
      Gadget g(n);
       // ...
       if (x < 100) throw std::run_time_error("Weird!!");
       if (x < 200) return;

    Its amazing to see how C++ is catching up with .NET.
    I've always been a C++ guy.

    Thanks again.