horses.cpp: In function 'std::__cxx11::string cmp(std::__cxx11::string, std::__cxx11::string)':
horses.cpp:7:29: warning: declaration of 'a' shadows a global declaration [-Wshadow]
string cmp(string a,string b){
^
horses.cpp:4:22: note: shadowed declaration is here
struct year{int x,y;}a[500100];
^
horses.cpp:8:20: warning: conversion to 'int' from 'std::__cxx11::basic_string<char>::size_type {aka long unsigned int}' may alter its value [-Wconversion]
int la=a.length(),lb=b.length();
~~~~~~~~^~
horses.cpp:8:34: warning: conversion to 'int' from 'std::__cxx11::basic_string<char>::size_type {aka long unsigned int}' may alter its value [-Wconversion]
int la=a.length(),lb=b.length();
~~~~~~~~^~
horses.cpp: In function 'int mod(std::__cxx11::string)':
horses.cpp:17:17: warning: declaration of 'a' shadows a global declaration [-Wshadow]
int mod(string a){
^
horses.cpp:4:22: note: shadowed declaration is here
struct year{int x,y;}a[500100];
^
horses.cpp:19:19: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (int i=0;i<a.length();i++){
~^~~~~~~~~~~
horses.cpp:23:12: warning: conversion to 'int' from 'long long int' may alter its value [-Wconversion]
return tmp;
^~~
horses.cpp: In function 'std::__cxx11::string mul(std::__cxx11::string, int)':
horses.cpp:27:19: warning: conversion to 'int' from 'std::__cxx11::basic_string<char>::size_type {aka long unsigned int}' may alter its value [-Wconversion]
s[0]=sa.length();
~~~~~~~~~^~