how can I declare linkedlist (the ready implemented linkedlist in c++)

just include <list> header file. See this link

#include <list>

using std::list

int main()
{
    list<int> MyList;

}