A program allows a user to save passwords used to log in to websites. A stored password is then inserted automatically when the user logs in to the corresponding website. A global 2D array Secret of type STRING stores the passwords together with the website domain name where they are used. Secret contains 1000 elements organised as 500 rows by 2 columns. Unused elements contain the empty string (""). These may occur anywhere in the array. An example of a part of the array is: Array element Value Secret [27, 1] "thiswebsite.com" Secret [27, 2] "............" Secret [28, 1] "thatwebsite.com" Secret [28, 2] "............" Note: • For security, the passwords are stored in an encrypted form, shown as "............" in the example. • The passwords cannot be used without being decrypted. • You may assume the encrypted form of a password will NOT be an empty string. The programmer has started to define program modules as follows: Module Description Exists() • Takes two parameters: ○ a string • a character • Performs a case-sensitive search for the character in the string • Returns TRUE if the character occurs in the string, otherwise returns FALSE Encrypt() • Takes a password as a parameter of type string • Returns the encrypted form of the password as a string Decrypt() • Takes an encrypted password as a parameter of type string • Returns the decrypted form of the password as a string Note: in a case-sensitive comparison, 'a' is not the same as 'A'.
✓ Correct Answer
The correct answer is —. This question tests the candidate's understanding of algorithms and data structures within the Computer Sciencesyllabus. The examiner's mark scheme requires...
📋 Examiner Report & Trap Analysis
Common mistake: 62% of candidates selected the distractor because they confused... The examiner specifically designed this question to test whether students can differentiate between... To secure full marks, candidates must demonstrate...
Unlock the Examiner's Answer
Sign up for free to reveal the correct answer, the official mark scheme breakdown, and the examiner trap analysis for this question.
Sign Up Free to Unlock →Join thousands of Cambridge students already using Oracle Prep