App Dev Worksheet: Final Test
Developer's tip (Plan, design, build, check): Find the topic: what apps are, designing apps, or logic and building. Read every screen, list or code line carefully, top to bottom. For code, write each value down step by step and check it again.
NameDateTime takenScore ___ / 40
-
1.🧪 One test case fails. Which one?
📝 Rule: a quiz is passed with 7 or more right answers.
function result(right) {
if (right > 7) {
return "Pass";
}
return "Try again";
}
Test 1: result(4) → expected Try again
Test 2: result(9) → expected Pass
Test 3: result(7) → expected Pass (a) Test 3 (b) Test 2 (c) Test 1 - 2.🎯 An app for “everyone” with no clear user usually ___. (a) wins every prize (b) is easy to build (c) needs no testing (d) helps nobody well
-
3.⚙️ Which line does the processing (works out the answer)?
line 1: let bill = 39; // typed by the user
line 2: let friends = 3; // typed by the user
line 3: let share = bill / friends;
line 4: show(share); (a) line 3 (b) line 2 (c) line 4 (d) line 1 - 4.🔍 Which is the odd one out? (a) spot a problem to solve (b) talk to possible users (c) list what users need (d) try every button
-
5.🔀 What number does this shop app show?
let total = 700;
if (total > 500) {
total = total - 50;
}
show(total); -
6.🔘 Our rule: buttons are at least 48 px tall. Which button is too small?
Back button: 28 px tall
Cancel button: 52 px tall
Start button: 72 px tall (a) Back (b) Start (c) Cancel - 7.Which of these requests is fair? (a) calculator → location (b) torch → contacts (c) timer → your photos (d) map app → location
-
8.🔘 Our rule: buttons are at least 48 px tall. How many of these buttons follow the rule?
Send button: 64 px tall
Cancel button: 40 px tall
Next button: 64 px tall - 9.True or false: a medicine reminder solves no real problem. (a) True (b) False
- 10.💾 Where should the app save your last game level: on the phone or in the cloud? (a) in the cloud (b) on the phone
- 11.🗒️ You are planning version 1 of a pocket-money tracker. Which feature can WAIT for a later version? (a) pie-chart colours (b) show the balance (c) add money received (d) add money spent
-
12.🧰 What number does this code show?
function double(n) {
return n * 2;
}
show(double(15)); - 13.True or false: buttons almost touching is good button design. (a) True (b) False
- 14.🐞 A comment in code (after //) is for ___. (a) the phone screen (b) people reading the code (c) the app store (d) the battery
- 15.Which of these is a user need? (a) a dark mode switch (b) a share button (c) “What should I cook?” (d) a reminder alarm
- 16.📱 Which one has a home-screen icon: an app or a website? (a) an app (b) a website
- 17.🔁 What does a loop do? (a) repeats code (b) saves photos (c) deletes code (d) draws icons
-
18.🧰 What does this code show?
function greet(name) {
return "Hi, " + name + "!";
}
show(greet("Meera")); (a) greet (b) Hi, name! (c) Meera (d) Hi, Meera! -
19.🔁 What number does this code show?
let marks = [13, 7, 18, 13, 6];
let best = 0;
for (let i = 0; i < marks.length; i++) {
if (marks[i] > best) {
best = marks[i];
}
}
show(best); - 20.🔘 Is this good or poor button design: a big, easy tap area? (a) poor design (b) good design
- 21.🌐 Which program do you need to open a website? (a) a calculator (b) a web browser (c) a camera app (d) an app store
- 22.✏️ What is a wireframe? (a) the finished app (b) a simple screen sketch (c) a type of password (d) a charging cable
- 23.💡 Does an app idea like a library due-date alert solve a real problem? (a) Yes (b) No
-
24.🗒️ Version 1 of a bus tracker must be ready in 10 days. How many days are left for extras after the must-haves?
see where the bus is: 1 days
show arrival time: 4 days
pick your bus stop: 4 days - 25.🔍 Which is the odd one out? (a) how many taps it takes (b) how users feel after (c) how easy sign-up is (d) the screen layout
-
26.🔀 What does this PIN rule show?
let pin = "73697";
if (pin.length === 4) {
show("PIN saved");
} else {
show("Use 4 digits");
} (a) PIN saved (b) Use 4 digits -
27.🧪 How many of these test cases pass?
🎟️ Rule: a ticket costs 50 for children under 11, and 100 for everyone else.
function price(age) {
if (age <= 11) {
return 50;
}
return 100;
}
Test 1: price(13) → expected 100
Test 2: price(8) → expected 50
Test 3: price(12) → expected 100 -
28.👆 The user taps the button 3 times. What number does the label show now?
let stars = 6;
button.onTap = function () {
stars = stars + 4;
label.text = stars;
}; -
29.🧰 What number does this code show?
function triple(n) {
return n * 3;
}
show(triple(21)); - 30.🔀 When does the else part run? (a) never (b) when the test is true (c) always (d) when the test is false
-
31.🔀 What number does this shop app show?
let total = 390;
if (total > 500) {
total = total - 50;
}
show(total); -
32.🐞 Each comment says what its line SHOULD do. Which line has the bug?
line 1: let score = 38; // start at 38
line 2: score = score * 3; // double it
line 3: score = score + 3; // add 3
line 4: show(score); // show it (a) line 1 (b) line 3 (c) line 2 - 33.True or false: speaking a command is processing. (a) False (b) True
- 34.🔐 Is this permission request fair or too much: calling app → contacts? (a) too much (b) fair
-
35.🔁 What number does this code show?
let scores = [57, 10, 18];
let count = 0;
for (let i = 0; i < scores.length; i++) {
if (scores[i] >= 60) {
count = count + 1;
}
}
show(count); - 36.Which of these is true of a website? (a) comes from an app store (b) has a home-screen icon (c) is installed on a phone (d) needs no installing
-
37.🔀 What does this sign-up rule show?
let age = 11;
if (age >= 13) {
show("Welcome!");
} else {
show("Ask a parent");
} (a) Ask a parent (b) Welcome! - 38.⚙️ In an app, is tapping a button an input, processing or an output? (a) input (b) processing (c) output
-
39.🔀 What does this battery rule show?
let battery = 57;
if (battery < 20) {
show("Low battery");
} else {
show("Battery OK");
} (a) Low battery (b) Battery OK -
40.⚙️ What number does this app show?
let price = 40; // typed by the user
let qty = 6; // typed by the user
let total = price * qty;
show(total);
Answer key
- Test 3
- helps nobody well
- line 3
- try every button
- 650
- Back
- map app → location
- 2
- False
- on the phone
- pie-chart colours
- 30
- False
- people reading the code
- “What should I cook?”
- an app
- repeats code
- Hi, Meera!
- 18
- good design
- a web browser
- a simple screen sketch
- Yes
- 1
- the screen layout
- Use 4 digits
- 3
- 18
- 63
- when the test is false
- 390
- line 2
- False
- fair
- 0
- needs no installing
- Ask a parent
- input
- Battery OK
- 240
Free app development lessons, practice and worksheets at talentjr.in/app-development-for-students