MCQs / Computer Science / Course Project: Build a Modern Cloud App Step by Step
Course Project: Build a Modern Cloud App Step by Step MCQs — Computer Science 52 multiple-choice questions on Course Project: Build a Modern Cloud App Step by Step from Computer Science, each with the correct answer and, where available, a teacher's explanation. Read through them to revise the chapter, then practise the same questions one by one to test yourself.
1. Why does AboutActivity override shouldOverrideUrlLoading? To block the page To cache the page To open mailto and web links in the right apps instead of inside the WebView To enable JavaScript Answer: C) To open mailto and web links in the right apps instead of inside the WebView
Explanation: Returning true means the app handled the link.
Discuss this question
2. RegisterActivity sends the new email back to AuthActivity using: SharedPreferences only setResult(RESULTOK, Intent().putExtra("email", email)) A global static variable A notification Answer: B) setResult(RESULTOK, Intent().putExtra("email", email))
Explanation: Lab 4 – activity result with an extra.
Discuss this question
3. Why is the Delete button visible only on your own events? Because of dark mode Supabase hides other buttons event.userId is compared with Prefs.userId (and RLS enforces it on the server) It is random Answer: C) event.userId is compared with Prefs.userId (and RLS enforces it on the server)
Explanation: The UI hides it; RLS is the real protection.
Discuss this question
4. Why do all project options use a record with a title, date/time, location and contact? Because RecyclerView needs four fields To make the APK smaller So every lab feature (countdown, map, location, call, SMS, email) fits any idea Because Supabase requires exactly these columns Answer: C) So every lab feature (countdown, map, location, call, SMS, email) fits any idea
Explanation: The shared shape lets one set of steps work for every project idea.
Discuss this question
5. In the Feedback screen, the 10-second countdown gives the user: An undo window before the feedback is sent A delay to load the map Time to grant permissions A quiz timer Answer: A) An undo window before the feedback is sent
Explanation: Lab 17 + Lab 13.
Discuss this question
6. Why is the countdown started in onStart() and cancelled in onStop()? onCreate cannot create timers To avoid internet use It runs only while the screen is visible, saving battery Timers only work in onStart Answer: C) It runs only while the screen is visible, saving battery
Explanation: Lifecycle-aware work saves power.
Discuss this question
7. How is an Event passed from HomeFragment to EventDetailActivity? With a static variable Through a Supabase call As a JSON string extra created with Gson In a notification Answer: C) As a JSON string extra created with Gson
Explanation: putExtra("event", Gson().toJson(e)) and fromJson on the other side.
Discuss this question
8. For a class project, switching off "Confirm email" means: Passwords are not needed RLS is disabled Emails are deleted New users can sign in immediately after registering Answer: D) New users can sign in immediately after registering
Explanation: Otherwise users must confirm by email first.
Discuss this question
9. In the events table, userid has default auth.uid(). This means: Anonymous users own events The owner is filled from the signed-in user's token, so the app never sends it Every event belongs to the admin The id is random Answer: B) The owner is filled from the signed-in user's token, so the app never sends it
Explanation: Nobody can post as someone else.
Discuss this question
10. Which CampusPulse policy stops users deleting other users' events? for insert with check (true) for delete to authenticated using (auth.uid() = userid) No policy is needed for select using (true) Answer: B) for delete to authenticated using (auth.uid() = userid)
Explanation: Only matching rows can be deleted.
Discuss this question
11. Why must you keep the .jks key store file safe? It stores user data Every future update must be signed with the same key It is needed to run the emulator It contains the Supabase password Answer: B) Every future update must be signed with the same key
Explanation: A lost key means you cannot publish updates.
Discuss this question
12. The avatar is shown as a circle by: RecyclerView A circular PNG only ShapeableImageView with a 50% corner-size shape overlay A WebView Answer: C) ShapeableImageView with a 50% corner-size shape overlay
Explanation: Material shape theming.
Discuss this question
13. MaterialDatePicker returns the selected date as: A LocalDateTime in local time A String in dd/MM/yyyy UTC milliseconds at midnight Seconds since 2000 Answer: C) UTC milliseconds at midnight
Explanation: Convert with Instant.ofEpochMilli(...).atZone(ZoneOffset.UTC).toLocalDate().
Discuss this question
14. Before calling getCurrentLocation(), the app must: Show a notification Be signed in to Supabase Have internet permission only Have location permission granted at runtime Answer: D) Have location permission granted at runtime
Explanation: Lab 15 – ACCESSFINE/COARSELOCATION runtime permission.
Discuss this question
15. Why does AddEventFragment override onSaveInstanceState? To keep the picked date, time and location when the phone rotates To upload the event To request permissions To clear the form Answer: A) To keep the picked date, time and location when the phone rotates
Explanation: Plain variables are lost on configuration change unless saved.
Discuss this question
16. Which test proves the app handles network failures? Turn on airplane mode and refresh – a friendly message with Retry appears Uninstall the app Rotate the phone Change the font size Answer: A) Turn on airplane mode and refresh – a friendly message with Retry appears
Explanation: Offline testing.
Discuss this question
17. For Google Play you normally upload: An .ipa file local.properties An Android App Bundle (.aab) The .jks file Answer: C) An Android App Bundle (.aab)
Explanation: Play generates optimised APKs from the bundle.
Discuss this question
18. addEvent() returns the saved row because the request has: Prefer: return=representation select= @Query("id") order=startsat.asc Answer: A) Prefer: return=representation
Explanation: Without it the insert returns an empty body.
Discuss this question
19. Prefs.darkMode stores the setting with: The WebView SharedPreferences A static variable only A Supabase table Answer: B) SharedPreferences
Explanation: Lab 10 – small settings live in SharedPreferences.
Discuss this question
20. enableEdgeToEdge() with window insets lets the app: Draw behind the system bars while keeping content readable Run in split screen only Disable rotation Remove the status bar permanently Answer: A) Draw behind the system bars while keeping content readable
Explanation: Insets add padding so the toolbar is not under the status bar.
Discuss this question
21. DateValidatorPointForward.now() in the date picker: Sets the time to now Saves the date to Supabase Stops the user picking past dates Opens the clock Answer: C) Stops the user picking past dates
Explanation: Calendar constraints validate the selection.
Discuss this question
22. Why does AuthActivity call finish() after opening MainActivity? To clear the database So pressing Back does not return to the sign-in screen To rotate the screen To log the user out Answer: B) So pressing Back does not return to the sign-in screen
Explanation: finish() removes the activity from the back stack.
Discuss this question
23. Why does the project use minimum SDK 26? Retrofit needs API 34 Material 3 needs Android 14 java.time works without extra setup and almost all phones support it Supabase only works on Android 8 Answer: C) java.time works without extra setup and almost all phones support it
Explanation: java.time is available natively from API 26.
Discuss this question
24. Which architecture describes CampusPulse? Peer-to-peer Mainframe batch Presentation (app) – logic (repository, RLS) – data (Supabase PostgreSQL) Single-tier desktop Answer: C) Presentation (app) – logic (repository, RLS) – data (Supabase PostgreSQL)
Explanation: A three-tier cloud-connected app.
Discuss this question
25. deleteEvent sends @Query("id") with the value "eq.$id" because: Retrofit cannot send plain ids PostgREST filters use column=operator.value Supabase needs the word eq in every URL It encrypts the id Answer: B) PostgREST filters use column=operator.value
Explanation: DELETE /rest/v1/events?id=eq.<id.
Discuss this question
Page 1 of 3 Next
Practise Course Project: Build a Modern Cloud App Step by Step MCQs
More Computer Science chapters