Probably very easy although I do not understand the question. You need to differentiate between pic and pic. Im geussing one is a Picture the other is to "pick" a "Picture"
You can ask the question a different way: You have a set of values from 1 to, say, 10,000 (1 = picture1, 2 = picture2, etc). You want to generate a set of unique random numbers. See this thread for a few ways to do that: How can I generate multiple unique random numbers?