i'm trying to get Serial Number in android
in this answer Thaussma said that
in Android 8 and later (>= SDK 26) use android.os.Build.getSerial() which requires the dangerous permission READ_PHONE_STATE. Using android.os.Build.SERIAL returns android.os.Build.UNKNOWN.
but when i tried android.os.Build.getSerial()
with required permission i got cannot resolve method 'getSerial()'
error