The floppy disk used for the BAPC. CC0 1.0 by Peter Astbury on Wikimedia Commons You are working on your new problem for the Benelux Algorithm Programming Contest (BAPC): FizzBuzz. Given two natural numbers $$$a$$$ and $$$b$$$, the contestant's program should print the natural numbers in ascending order, starting at (1), with three exceptions:
Unfortunately, this year, the budget for the BAPC is rather minimal. Therefore, the output of the contestants is stored on floppy disks which can only hold (1440) KiB (({1 474 560}) bytes). It is your job to make sure that the correct output of a solution fits on such a floppy disk.
Given such $$$a$$$, $$$b$$$, and a natural number $$$n$$$, up to which integer (k) does the FizzBuzz sequence of (k) integers fit in (n) characters? Whitespace such as newlines or spaces should not be counted as characters.
An example of a FizzBuzz sequence of $$$11$$$ integers for $$$a=2$$$ and $$$b=3$$$ is given by this string of length $$$37$$$: "1FizzBuzzFizz5FizzBuzz7FizzBuzzFizz11".
The input consists of:
Output the largest integer (k), such that the FizzBuzz sequence from (1) up to and including (k) requires at most (n) bytes of storage.
2 3 10
3
2 4 15
5
| Name |
|---|


