AMC 10B 2018 Problem 21

Mary chose an even 4-digit number n. She wrote down all the divisors of n in increasing order from left to right: 1,2, \ldots, \dfrac{n}{2}, n. At some moment Mary wrote 323 as a divisor of n. What is the smallest possible value of the next divisor written to the right of 323 ?

Answer Choices
A. 324
B. 330
C. 340
D. 361
E. 646