read enter in c
snippet in c

read enter in c

user870

char prev = 0;

while(1) {
    char c = getchar();
    if (c == '\n' && prev == c) break; // double return pressed!
    prev = c; 
}