8 In Tip-Top Condition
Should I go to Barcelona at Easter? If I have the money, there are flights available and I can get a hotel, then I'll go. Life is full of decisions: should I take that job? Should I join a gym? Should I make a cup of tea? Whenever you make a decision, you will consider a number of options and in the end you will either decide to do something or you will choose not to. As you embark on your programming career you may be thinking, if this doesn't get any easier then I'll stick to producing artwork. In this chapter we look at making decisions in your programs using the marvellous ‘if’ statement. An ‘if’ statement takes a logical argument that resolves to true or false; none of the difficult in-between concepts for a computer, ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access