I'm getting the following errors:
Code:
ucfParking.c: In function main:
ucfParking.c:22: error: stray \342 in program
ucfParking.c:22: error: stray \200 in program
ucfParking.c:22: error: stray \223 in program
ucfParking.c:22: error: expected ) before absExp
ucfParking.c:24: warning: format %d expects type int, but argument 2 has type int *
here's my code:
Code:
ucfParking.c: In function main:
#include <stdio.h>
int main(void)
{
int timeOfDay, availableSpots, permitsGiven, totalTime, absExp;
printf("What hour are you looking for parking?\n");
scanf("%d", &timeOfDay);
printf("How many spots are available this semester?\n");
scanf("%d", &availableSpots);
printf("How many parking permits were given this semester?\n");
scanf("%d", &permitsGiven);
absExp = abs(12-timeOfDay);
totalTime = (12 absExp)*permitsGiven/availableSpots;
printf("You will have to wait %d minutes to find parking.\n", &totalTime);
return 0;
}