#include<iostream> struct st{ int main(){ } can you please help me to why this line is not working “ cout<<"Enter your id"<<endl;
using namespace std;
char name[50];
int id;
};
struct st s[3];
cout<<"Student please enter their name: "<<endl;
cin>>s[1].name;
cout<<"Enter your id"<<endl;
cin>>s[1].id;
cin>>s[1].id ; ”
It is working as expected – https://ideone.com/blXDa2