Skip to content

Instantly share code, notes, and snippets.

@denysonique
Forked from anonymous/gist:1365151
Created November 14, 2011 21:03
Show Gist options
  • Save denysonique/1365154 to your computer and use it in GitHub Desktop.
Save denysonique/1365154 to your computer and use it in GitHub Desktop.
//wyświetla wszystkie argumenty, w nawiasie podając ich długość
int dl_napisu(char n[]) {
int i = 0;
while(n[i] != 0)
i++;
return i;
}
int main(int N, char* argv[]){
int i;
i = 0;
while(i < N){
printf("parametr nr%d:%s (%d)\n", i+1, argv[i], dl_napisu(argv[i])),
i = i + 1;}
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment