Increasing decreasing sequence

For my code, the test case 8 is failing and I have no clue is wrong with the code.
Question:
Given an array S of size N , check if it is possible to split sequence into two sequences -
s1 to si and si+1 to sN such that first sequence is strictly decreasing and second is strictly increasing. Print true/false as output.

Input Format

First line contains a single integer N denoting the size of the input.
Next N lines contain a single integer each denoting the elements of the array S.

Code:
#include
#include<string.h>
using namespace std;
int main() {
int size, mode=0;
long long int new_value,last_value=1000000000;
string flag=“true”;
//mode=0 checks for decreasing
cin>>size;
for(int i=0;i<size;i++)
{
cin>>new_value;
if(mode==0)
{
if(new_value>last_value)
{
mode=1;
last_value = 0;
}
else
{
last_value=new_value;
}
}
else
{
if(new_value<last_value)
{
flag=“false”;
}
else
{
last_value=new_value;
}
}
last_value = new_value;
}
cout<<flag<<endl;
return 0;
}