All pastes #205393 Raw Edit

Untitled

public text v1 · immutable
#205393 ·published 2006-10-16 19:34 UTC
rendered paste body
#include <stdio.h>
#include <iostream.h>

int main(int argc, char *argv[]) {
char *host,*nflag,*gotowe;
host=argv[1];
cout << "Runned with parameters:\n";
for(unsigned int i=0;i<argc;i++){
if(strcmp(argv[i],"-n")==0) {
nflag=argv[i+1];
cout << "n = " << nflag << endl;
}
}
cout << "Host: " << host;
//for(unsigned int j=0;j<int(nflag);j++) {
//sprintf(gotowe,"touch %s",host);
//system(gotowe);
//cout << gotowe;
//cout << j;
//}
}