I'm not sure what I'm doing wrong, but I canβt read the take from the console. For some reason, reading is wonderful. I am using Xcode.
double n1; // get input from the user printf("Enter first number: "); scanf("%f", &n1); printf("%f", n1);
This will always print 0 no matter what I enter.
source share