Hello!
I have a problem: i ask some information fron the user, but when I compile the program, it shows that there is mistake in data entry and gives error message: invalid operands to binary &
Help and tips would be very helpful
a piece of code, that the problem is :
(and sorry for my bad english, hope you understand )
Code:
#include <stdio.h>
#include <malloc.h>
#include <string.h>
//Põhiprogramm
main()
{
int I, L, H;
char R[50], E[50], P[50], T[50], K[50];
printf("Sisesta raamatu nimi: ");
scanf("%s" &R);
printf("\n");
printf("Sisesta raamatu ilmumisaasta: ");
scanf("%d" &I);
printf("\n");
printf("Sisesta raamatu lehekülgede arv: ");
scanf("%d" &L);
printf("\n");
printf("Sisesta raamatu autori eesnimi: ");
scanf("%s" &E);
printf("\n");
printf("Sisesta raamatu autori perekonnanimi: ");
scanf("%s" &P);
printf("\n");
printf("Sisesta raamatu keel (nt. est, eng): ");
scanf("%s" &K);
printf("\n");
printf("Kas oled lugenud seda raamatut (loetud/lugemata): ");
scanf("%s" &T);
printf("\n");
printf("Sisesta raamatu hinne (1 - 10): ");
scanf("%d" &H);
printf("\n\n");
system("pause");
}