How to know if the Variable is Categorical or Numerical if all it contains is Digits?
The short answer, is: your knowledge of the problem domain / application domain will tell you.
There are some differences that you look for, but to apply these differences, you will still have to use some domain knowledge (sometimes common sense).
The following are some differences which will help you distinguish:

For categorical variables, the set of permitted values is usually fixed, and rarely changes, if at all. In contrast, for numeric variable, the set of values can change, for example, when you receive a new record for the same dataset.
Numeric variables can potentially have values that are not round integers. In your example, even though "distance from office" happens to have integer values, that could be purely incidental, or could have been a choice made by some one about how much numeric precision they want in the data.
For categorical variables, it usually doesn't make sense to talk of averages. For example, there are 2 types of diabetes called Type 1, Type 2, but it just doesn't make sense to talk of an average of these types (Type 1.2357?).
Ask yourself this thumb-rule question: When I perform my data analysis can I express my inferences in terms of specific values of this variable? How about ranges of this variable ("0 to 5 km", "5 to 10 km", etc). For example, can I report any inferences from my data analysis that says "Those whose distance from office is 123, are prone to be successful in their career"? That specific value sounds silly, right? In contrast, if it were a categorical variable such as Type 2 Diabetes, you can always make inferences in terms of the specific value.
I have a dataset which has several Variables. 
I want to determine that how can we judge for a variable if it is categorical or numerical other than the method of unique value counts, as for instance one of my variable Disease Type has 31 Unique Values whereas other Variable Distance from Office has 25 Unique Values, both in the form of numbers.