O'Reilly logo

Dart for Absolute Beginners by David Kopec

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 4

image

Five Small Programs to Showcase Fundamentals in Dart

In Chapter 3, you learned some programming fundamentals that should have given you a basic understanding of a few of the concepts we will require to write programs. In this chapter, we will demonstrate those fundamentals in action. The following programs will all fit entirely within the main() function.

Number Guessing Game

I’m thinking of a number. Can you guess what it is? It’s ten, because that’s about the number of minutes that I think it will take you to input the Number Guessing Game into Dart Editor. Create a new command-line application in Dart Editor called “NumberGuessingGame.” ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required