Photo AI
Question 4
A library gives each book a code made from the first three letters of the book title in upper case, followed by the last two digits of the year the book was publishe... show full transcript
Step 1
Step 2
Answer
start
// Input title and year from user
output "Enter title:"
input title
output "Enter year:"
input year
// Use the librarycode function to get the book code
code = librarycode(title, year)
// Permanently store the new book code to the file 'bookcodes.txt'
open file "bookcodes.txt" for appending
write code to file
close file
end
Report Improved Results
Recommend to friends
Students Supported
Questions answered
CPU Architecture, Performance & Embedded Systems
Computer Science - AQA
Primary & Secondary Storage
Computer Science - AQA
Data Storage & Compression
Computer Science - AQA
Networks & Topologies
Computer Science - AQA
Wired & Wireless Networks, Protocols & Layers
Computer Science - AQA
Identifying & Preventing Threats to Computer Systems & Networks
Computer Science - AQA
Operating Systems & Utility Software
Computer Science - AQA
Ethical, Legal, Cultural & Environmental Impact
Computer Science - AQA
Computational Thinking, Searching & Sorting Algorithms
Computer Science - AQA
Designing, Creating & Refining Algorithms
Computer Science - AQA
Programming Fundamentals & Data Types
Computer Science - AQA
Additional Programming Techniques
Computer Science - AQA
Defensive Design & Testing
Computer Science - AQA
Boolean Logic Diagrams
Computer Science - AQA
Programming Languages & Integrated Development Environments (IDEs)
Computer Science - AQA
OCR Exam Reference Language
Computer Science - AQA