Professor Halfbrain has spent his entire weekend by filling $10\times10$ tables with the digits $0,1,2,3,4,5,6,7,8,9$ so that each digit occurs exactly $10$ times. According to the professor, such fillings are called legal fillings. Halfbrain detected oodles and oodles of fascinating legal fillings, and he derived two extremely deep theorems on them:
Professor Halfbrain's first theorem: In every legal filling of a $10\times10$ table, there exists a row or a column that contains at least two different digits.
Professor Halfbrain's second theorem: There exists a legal filling of a $10\times10$ table, in which every row and every column contain at most ten different digits.
This puzzle asks you to improve the two theorems of professor Halfbrain and to make them even deeper. Find an integer $x$, so that "at least two different digits" in the first theorem may be replaced by "at least $x$ different digits", and so that "at most ten different digits" in the second theorem may be replaced by "at most $x$ different digits" (again yielding true statements, of course).