【Android】偵測 android 版本

Build.VERSION mBuild = new android.os.Build.VERSION();
Toast.makeText(this, "SDK version-->"+String.valueOf(mBuild.SDK_INT), Toast.LENGTH_LONG).show();