horses.cpp: In function 'void pre()':
horses.cpp:12:6: warning: unused variable 'last' [-Wunused-variable]
int last=-1;
^~~~
horses.cpp: In function 'long long int find()':
horses.cpp:30:19: warning: conversion to 'int' from 'std::vector<int>::size_type {aka long unsigned int}' may alter its value [-Wconversion]
int last=a.size()-1, ind=a.size();
~~~~~~~~^~
horses.cpp:30:33: warning: conversion to 'int' from 'std::vector<int>::size_type {aka long unsigned int}' may alter its value [-Wconversion]
int last=a.size()-1, ind=a.size();
~~~~~~^~
horses.cpp:32:5: warning: declaration of 'now' shadows a global declaration [-Wshadow]
ll now=rmq(a[last], n-1);
^~~
horses.cpp:8:4: note: shadowed declaration is here
ll now=1;
^~~
horses.cpp:33:20: warning: conversion to 'int' from 'std::vector<int>::size_type {aka long unsigned int}' may alter its value [-Wconversion]
for(int i=a.size()-1; i>=0 && now<mod; i--){
~~~~~~~~^~
horses.cpp:40:20: warning: conversion to 'int' from 'std::vector<int>::size_type {aka long unsigned int}' may alter its value [-Wconversion]
for(int i=a.size()-2; i>=ind; i--){
~~~~~~~~^~
horses.cpp: In function 'int init(int, int*, int*)':
horses.cpp:55:13: warning: conversion to 'int' from 'long long int' may alter its value [-Wconversion]
return find();
~~~~^~
horses.cpp: In function 'int updateX(int, int)':
horses.cpp:58:17: warning: unused parameter 'pos' [-Wunused-parameter]
int updateX(int pos, int val) {
^~~
horses.cpp:58:26: warning: unused parameter 'val' [-Wunused-parameter]
int updateX(int pos, int val) {
^~~
horses.cpp: In function 'int updateY(int, int)':
horses.cpp:62:17: warning: unused parameter 'pos' [-Wunused-parameter]
int updateY(int pos, int val) {
^~~
horses.cpp:62:26: warning: unused parameter 'val' [-Wunused-parameter]
int updateY(int pos, int val) {
^~~