HelpContactFor teachers and institutes
>_StemPy Lab
Mock TestsClasses

>_StemPy Lab

Learn. Solve. Code the solutions. Test yourself.

Live examsFree mock exams, timed and rankedEveryone starts together, and your score and rank come the moment it ends.See the exams →

Learn

  • Physics
  • Chemistry
  • Mathematics
  • Biology
  • Python Programming
  • Statistics & Data Science
  • Computer Science
  • Classes
  • Groups

Practice

  • Problems
  • Quizzes
  • Mock Tests
  • Prepare for an Exam
  • Question Sets
  • Exams
  • Certificates
  • Python Labs
  • AI Practice Generator
  • Student-Created Tests

Community

  • Discussions
  • Resources
  • Notes
  • Glossary
  • Blog

Account

  • Log in
© 2026 senLearn. All rights reserved.HelpFor SchoolsAboutContactPrivacy PolicyTerms of UseRefund Policy
  1. Problems
  2. /The valid book number 9781861978769 is typed into a library system, but the 7th and 8th digits are…
MediumComputer ScienceHigh School (9–10)Computer Science › Data TransmissionNumericalConceptualIGCSE

The valid book number 9781861978769 is typed into a library system, but the 7th and 8th digits are…

StemPy LabContributed by StemPy Lab

Try it on paper first. A hint, the key idea and the worked solution are here when you need them.

The valid book number 9781861978769 is typed into a library system, but the 7th and 8th digits are swapped, giving 9781869178769.

  1. Using the weights 1,3,1,3,…1, 3, 1, 3, \dots1,3,1,3,… on all 131313 digits, find the total of the valid number.
  1. Find the total of the typed number.
  1. Is the typed number accepted? Explain why the weights 111 and 333 help to catch a swap.

Check your answer

Work it out on paper, then type your number. The answer itself stays hidden.

Need a reminder? The key ideaShowHide

A check digit is worked out from the other digits and catches data entry errors. ISBN-13 and bar codes: multiply the digits by 1,3,1,3,…1, 3, 1, 3, \dots1,3,1,3,… from the left and add; the check digit makes the total a multiple of 101010. ARQ: positive acknowledgement (no error), negative acknowledgement (error, resend), and a timeout after which the sender resends.

The worked solution

Have you tried it?

Work it out on paper first. It is fine to get stuck or make a mistake: that is how we learn. When you are ready, go through the solution one step at a time, and check each step against your own.

Step 1. The valid number. Its weighted total is 160160160, a multiple of 101010, as it must be.

Step 2. The typed number. The 7th and 8th digits were 111 and 999. Before the swap they gave 1×1+9×3=281 \times 1 + 9 \times 3 = 281×1+9×3=28. After the swap they give 9×1+1×3=129 \times 1 + 1 \times 3 = 129×1+1×3=12. The total falls by 161616: 160−16=144160 - 16 = 144160−16=144.

Step 3. Accepted? 144144144 is not a multiple of 101010, so the number is rejected and must be typed again.

Step 4. Why the weights help. The two swapped digits sit in places with different weights, 111 and 333. Swapping them changes the total by 2×2 \times2× the difference of the digits. If all the weights were 111, a swap would not change the total at all.

Answer: (a) 160160160. (b) 144144144. (c) No; the different weights make a swap change the total.

Log in to save this for later
← All Problems
← A library adds a new book. The first twelve digits of its 13-digit ISBN are 978186197876…A sender uses an automatic repeat query to send 8 packets, one at a time… →
More onComputer Science › Data Transmission

Discussion (0)

Log in to join the discussion.

Loading…

More on this topic

  1. A sender uses an automatic repeat query to send 8 packets, one at a time…Hard
  2. A library adds a new book. The first twelve digits of its 13-digit ISBN are 978186197876…Easy
  3. A computer sends the byte 01001101 to a device using an echo check…Easy
  4. The block of bytes 87, 142, 203 and 61 is sent with its checksum, worked out as the total bmod 256…Hard
  5. A block holds the four bytes 87, 142, 203 and 61…Medium
All problems on this topic →