Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- main{
- char *arr[10];
- int i = 0;
- while(1){
- char* str = (char*)calloc(10, sizeof(char));
- str = scanf(...);
- arr[i] = str;
- i++
- }
- int j;
- for(j = 0; j < 5; j++){
- printf("-slovo %d: %s\n", j, stringArr[i]); //pokazde vypisuje stejny string - ten posledni
- printf("-adresa %d\n\n", &(*stringArr[i])); //pokazde vypisuje stejne cislo
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment