I'm initialising an array of structures in main(); I get an error, when I declare and assign them separately.
This is my code snippet from main();
struct item newitem[10];
newitem[0]={1,"pen",5,10};
struct item new2= {2,"ygh",9,0};
This is the error I get on line 2. The line 3 works fine, however.
[Error] expected expression before '{' token
What could be the reason?