Just from seeing or hearing a sequence of 'white notes', there is no objective way to tell if you are in C or Am.
Subjectively, if you feel that the 'home note' (or 'tonic') that the piece is based around is 'A', then you can say it's in A minor. Likewise, if it's C, then it's C major - and if it's D, then it's D Dorian, and so on.
Richard and Tim have mentioned the leading tone as a possible clue. You might also want to look at which notes are most common. The IV and V note are often important. In C, these are F and G. In Am, these are D and E. So if you have lots of notes C, F and G, it might make it more likely that you are in C, while multiple occurrences of A, D and E might make A minor more likely.
You can also look at what the start and end note of melodic sections is, and what notes are played on the strong beats. A note played on a strong beat is more likely to be an important note in the key. This is also often true of notes that have long durations.
Still, all of these are just reasons for why you might feel that a melody is oriented around a certain note. If you don't feel that you can identify a tonic note that the melody is oriented around, but you still need to choose a key, then your choice is going to be somewhat arbitrary.
It's easier when you see a chord, since you can count the semitones between the notes and deduce if it's major or minor
Remember that telling whether a chord is major or minor is different to telling whether a key is major or minor.
You might still have a similar problem with chords to the one you described with notes - you might have a sequence of chords using the white notes and not be able to tell if that chord sequence is in C or Am.