Main.cc: In function ‘int main()’:
Main.cc:38:25: warning: format ‘%s’ expects argument of type ‘char*’, but argument 2 has type ‘char (*)[100]’ [-Wformat=]
scanf("%s", &str);
~~~~^
Main.cc:39:20: error: ‘strlen’ was not declared in this scope
len = (int)strlen(str);
^~~~~~
Main.cc:39:20: note: suggested alternative: ‘mbrlen’
len = (int)strlen(str);
^~~~~~
mbrlen
Main.cc: In function ‘int per(int, char*)’:
Main.cc:27:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
Main.cc: In function ‘int main()’:
Main.cc:38:14: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%s", &str);
~~~~~^~~~~~~~~~~~
Main.cc:48:11: warning: ignoring return value of ‘int system(const char*)’, declared with attribute warn_unused_result [-Wunused-result]
system("pause ");
~~~~~~^~~~~~~~~~