horses.cpp: In function 'std::__cxx11::string cmp(std::__cxx11::string, std::__cxx11::string)':
horses.cpp:8: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:9: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:9: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:18: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:20:19: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (int i=0;i<a.length();i++){
~^~~~~~~~~~~
horses.cpp: In function 'std::__cxx11::string mul(std::__cxx11::string, int)':
horses.cpp:40:19: warning: conversion to 'int' from 'long long int' may alter its value [-Wconversion]
for (int i=s[0];i>0;i--){
~~~^
horses.cpp: In function 'int init(int, int*, int*)':
horses.cpp:53:16: warning: declaration of 's' shadows a global declaration [-Wshadow]
string s=mul(ho,a[i].y);
^
horses.cpp:5:11: note: shadowed declaration is here
long long s[500100];
^
horses.cpp: In function 'int updateX(int, int)':
horses.cpp:65:16: warning: declaration of 's' shadows a global declaration [-Wshadow]
string s=mul(ho,a[i].y);
^
horses.cpp:5:11: note: shadowed declaration is here
long long s[500100];
^
horses.cpp: In function 'int updateY(int, int)':
horses.cpp:77:16: warning: declaration of 's' shadows a global declaration [-Wshadow]
string s=mul(ho,a[i].y);
^
horses.cpp:5:11: note: shadowed declaration is here
long long s[500100];
^