Alice Bob turn play game Alice start firstthere n stone pile on player turn remove stone pile receive point base stone value Alice Bob value stone differentlyYou give integer array length n alicevalue bobvalues each alicevaluesi bobvaluesi represent Alice Bob respectively value ith stoneThe winner person point stone choose if player point game result draw both player play optimally both player know valuesdetermine result game andIf Alice win return 1if Bob win return 1if game result draw return 0 example 1input alicevalue 13 bobvalue 21output 1ExplanationIf Alice take stone 1 0indexed Alice receive 3 pointsbob choose stone 0 receive 2 pointsalice winsexample 2input alicevalue 12 bobvalue 31output 0explanationif Alice take stone 0 Bob take stone 1 1 pointdrawexample 3input alicevalue 243 bobvalue 167output 1explanationregardless Alice play Bob able point AliceFor example Alice take stone 1 Bob stone 2 Alice take stone 0 Alice 6 point Bobs 7bob win Constraintsn alicevalueslength bobvalueslength1 n 1051 aliceValuesi bobvaluesi 100