#include <iostream>
#include<string>
template <typename T>
struct List {
struct node {
T key;
node* prev;
node* next;
};
node* first = nullptr;
node* last = nullptr;
// functions
};
//a function template List<T> where T is some type, as its parameter
template<typename T>
void palindrome(List<T> L)
{
std::cout<<"palindrome called"<<std::endl;
}
int main()
{
List<int> l1;
//call
palindrome(l1);//T will be deduced to int
List<double> l2;
//call
palindrome(l2); //T will be deduced to double
return 0;
}