Java Intermediate Solution
IntuitionApproachComplexity
Time complexity:

Space complexity:
Code
# Intuition
<!-- Describe your first thoughts on how to solve this problem. -->

# Approach
<!-- Describe your approach to solving the problem. -->

# Complexity
- Time complexity:
<!-- Add your time complexity here, e.g. $$O(n)$$ -->

- Space complexity:
<!-- Add your space complexity here, e.g. $$O(n)$$ -->

# Code
```java []
class Solution {
   	public static boolean hasSameDigits(String s) {
       String newStr = "";
        while(s.length() > 2){
            StringBuilder builder = new StringBuilder();
            for(int i = 0; i<s.length()-1; i++){
                builder.append((s.charAt(i)-48 + s.charAt(i+1)-48)%10);
            }
            newStr = builder.toString();
            s = newStr; 
           
        }
        return newStr.charAt(0) == newStr.charAt(1);
    }
}
```
['Java']