Well first let me tell you that your problems go much deeper than your template parameter woes. The logic in your program is a little messed up.
However, assuming you'll be able to fix that on your own once you overcome your template problems, try this:
Code:
#ifndef SSCR_H_INCLUDED
#define SSCR_H_INCLUDED
#include <iostream>
#include <vector>
template <class T>
void sscr(std::vector<std::vector<T> > v)
{
typename std::vector<std::vector<T> >::iterator i;
typename std::vector<T>::iterator j;
for (i = v.begin(); i != v.end(); i++) {
for (j = i->begin(); j != i->end(); j++)
std::cout << *j << " ";
std::cout << std::endl;
}
}
#endif // SSCR_H_INCLUDED
It limits you to passing in a vector of vectors, but I think that should be a pretty reasonable expectation.
Oh and there's no point having this function return 0. Just return 0 from your main function after you call this.