Dart က strongly typed language ဖြစ်တဲ့အတွက် value တစ်ခုချင်းစီမှာ type ရှိပါတယ်။ Type ကိုနားလည်ထားရင် error တွေလျော့ပြီး code intention ပိုရှင်းပါတယ်။
dart
void main() {
int students = 35;
double rating = 4.8;
String course = 'Dart Basic';
bool isPublished = true;
print(course.runtimeType);
print('Students: $students');
print('Rating: $rating');
print('Published: $isPublished');
}runtimeType က value ရဲ့ actual type ကိုကြည့်ချင်တဲ့အခါအသုံးဝင်ပါတယ်။ Debug လုပ်တဲ့အချိန် “ဒီ value က ဘာ type ဖြစ်နေလဲ” သိချင်ရင် စမ်းသုံးနိုင်ပါတယ်။
You should see
String Students: 35 Rating: 4.8 Published: true