mirror of
https://github.com/nisrulz/flutter-examples.git
synced 2025-11-09 04:58:58 +00:00
BMI calculator example (#130)
This commit is contained in:
19
bmi_calculator/lib/body_model.dart
Normal file
19
bmi_calculator/lib/body_model.dart
Normal file
@@ -0,0 +1,19 @@
|
||||
enum Sex {
|
||||
male,
|
||||
female,
|
||||
}
|
||||
|
||||
// User body model class
|
||||
class BodyModel {
|
||||
Sex sex;
|
||||
int height;
|
||||
int weight;
|
||||
int age;
|
||||
|
||||
BodyModel({
|
||||
required this.sex,
|
||||
required this.height,
|
||||
required this.weight,
|
||||
required this.age,
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user