Problem 1672. Leftovers? Again?!
I am thinking of a positive number X. To determine what number I am thinking of, I will give you two 1xN vectors. The first vector (V1) is several numbers, none of which will share a factor. The second vector (V2) is the remainder of X when divided by each of the numbers in V1. Calculate what the lowest possible value of X can be given these criteria. For example:
V1 = [2 3] ; V2 = [1 2]
would give an X value of 5. There are an infinite number of other values of X that would satisfy V1 and V2, but I want the lowest one.
Solution Stats
Problem Comments
-
8 Comments
Show
5 older comments
Rafael S.T. Vieira
on 18 Aug 2020
Apparently James is deleting essential files for Cody by using rm at his script. I've informed him of the issue.
goc3
on 29 Sep 2020
I have commented out the initial lines so that this problem is solvable again.
Rafael S.T. Vieira
on 29 Sep 2020
Thanks, goc3.
Solution Comments
Show commentsGroup

Indexing III
- 23 Problems
- 44 Finishers
- expand intervals vol.3
- remove single elements
- return row and column indices given 2 values which define a range
- expand intervals vol.2
- compress sequence into intervals
- expand intervals
- Max Change in Consecutive Elements
- remove single elements
- Back to basics - mean of corner elements of a matrix
- Time Expansion
- Three...is a magic number.
- counting groups!
- Largest territory
- Replace pattern 0 1 0 and 1 0 1
- Find the index of n in magic(n)
- Sum of odd numbers in a matrix
- return row and column indices given 2 values which define a range
- Another colon problem
- How unique?
- Finding neighbors of [-1:1] in a matrix....
- Find the maximum two numbers of every column of a matrix
- Index one element in each vector of an array along a given dimension
- Tridiagonal
- Index of a Rational number
- Sort numbers by outside digits
Problem Recent Solvers28
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!