I have search a lot but i haven't find my answer
I want to write a program that will give an array with 3 members
and then i want to print array with 3 members :
char array[3] ;
for(int i=0;i<3;i++){
cin>>array[i] ;}
But the point is , i don't want to cin array members in character ,and i want this in string ;
but the another point is i don't want to use #include <string.h>
what i have to do ?
I want to give input array from user in this form:
char array[3]={"input1","input2","input3"}
for(int i=0;i<3;i++){
cin>>array[i] ;
}
cout<<array[0]<<" "<<array[1]<<" "<<array[2] ;
//output = input1 input2 input3