How can I convert Persian/Arabic numbers to English in Kotlin? I saw similar qustions in java but It doesn't match my requirement. I want to pass Date as String to web service. when I get Date in devices that uses Persian localized digits are Persian and the server can't convert this String to DateTime. So I need to convert all digits to English. here is the Date that I receive in Devices with Persian Localized:
"۲۰۲۰/۰۸/۲۱"
and these are Persian/Arabic numbers
(۰ -> 0) (۱ -> 1) (۲ -> 2) (۳ -> 3) (۴ -> 4) (۵ -> 5) (۶ -> 6) (۷-> 7) (۸ -> 8) (۹ -> 9)
I need a fun in Kotlin to perform this.