title: How to find the time complexity of the below function?
body: <p>I am facing difficulty to figure out the time complexity of this below function. Please help to find how to solve this question?</p>
  <pre><code>    int sumOfDigits(int n){
      int sum;` 
      if(n &lt; 10){
          return n;
      }
      sum = (n % 10) + sumOfDigits(n / 10);
      return sum;
      }
  </code></pre>