Run ❯
Get your
own
website
❯
Run Code
Ctrl+Alt+R
Change Orientation
Ctrl+Alt+O
Change Theme
Ctrl+Alt+D
Change Language
Go to Spaces
Ctrl+Alt+P
void readScore(String text) { try { var score = int.parse(text); print('Score: $score'); } on FormatException { print('Invalid score: $text'); } finally { print('Done reading'); } } void main() { readScore('85'); readScore('high'); }
Score: 85
Done reading
Invalid score: high
Done reading