Possible Duplicate:
Why can templates only be implemented in the header file?
Main class
   int main() {
      initCarList();
   }
   void initCarList() {
        List<Car> carList;
        Car c1 = Car("Toyota", "Bettle", 5);
        carList.add(c1);
        Car c2 = Car("Mercedes", "Bettle", 7);
        carList.add(c2);
        Car c3 = Car("FireTruck", "Large Van", 20);
        carList.add(c3);
        Car c4 = Car("Puma", "Saloon Car", 10);
        carList.add(c4);
    }
List class
#include "List.h"
#include <iostream>
using namespace std;
template <typename ItemType>
class List {
private:
    ItemType itemList[10];
    int size;
public: 
    List();
    void add(ItemType);
    void del(int index);
    bool isEmpty();
    ItemType get(int);
    int length();
};
template<typename ItemType>
List<ItemType>::List() {
    size = 0;
}
template<typename ItemType>
void List<ItemType>::add(ItemType item) {
    if(size < MAX_SIZE) {
        itemList[size] = item;
        size++; 
    } else {
        cout << typename << " list is full.\n";
    }
}
I got errors like these
Error 3 error LNK2019: unresolved external symbol "public: void __thiscall List::add(class Car)" (?add@?$List@VCar@@@@QAEXVCar@@@Z) referenced in function "void __cdecl initCarList(void)" (?initCarList@@YAXXZ) C:\Users\USER\Desktop\New folder\DSA_Assignment\main.obj DSA_Assignment
Did I do anything wrongly in my code? NEED HELP THANKS!
 
     
     
    