after running this code it takes only 2 inputs when I give 3, if I don’t type cin.get( ) after cin>>n.
why does this happen?
also why does it take perfectly 3 inputs after typing 3. When not including cin.get() after cin>>n. And instead of typing for(int i=0; i<n ; i++), typing for(int i=0; i<=n ; i++) works, Shouldn’t for(int i=0; i<=n ; i++) be taking 4 inputs if i type 3?