Hi
I'm new to c and i got a problem using gets and scanf
here's the code:
#include <stdio.h>
after i enter the first input I cannot enter the second input. Is it the gets behaviour or something wrong with my code?Code:int main() { int input1; char input2[5]; printf( "Enter input : " ); scanf( "%d", &input1 ); printf( "Enter input : " ); gets( input2 ); printf( "%d, %s\ n", input1, input2 ); return 0; }