CPSC 110-08: Computing with Mobile Phones
Reading: App Inventor, Create Your Own Apps, Chapter 18
Due: Wednesday 9/28 (before class)
Textbook
You can purchase a copy of the text book
Wolber,
Abelson, Spertus, and Looney, App Inventor: Create Your Own Android
Apps. It costs around $25. We will be having reading assignments
from this text throughout the semester.
There is a
pre-publication version
of this book available for free download. However, it is not as complete
as the published version.
Reading Assignment
Principles addressed:
Algorithms: if, and if/else;
Programming:
Read the first few pages of Chapter
18, Programming Your App
to Make Decisions: Conditional Blocks, up through the
section on Programming Conditions Within Conditions.
This chapter describes the if and if/else control
structures, important elements in designing algorithms.
Reading Questions. Provide answers to the following
two questions on a Portfolio page for this reading assignment.
- Consider the following Pseudocode algorithm. What
would be the value stored in M as a result of this algorithm.
Set N to 200
Set M to 0
If N < 100 then-do:
Set M to 1
else-do: If N < 200 then do:
Set M to 2
else-do:
Set M to 3
- Construct a set of App Inventor Blocks to test your answer
to the previous question. Test your code by right clicking
on blocks and using the Watch and Do it options.
(Remember that to use those options your app must be running
on the emulator or phone.)
Provide a screen shot of your blocks as your answer to this question.
In Class on Wednesday
We will go over these and look at an example that uses if/ifelse blocks.