Doubt Regarding ArrayList.get() JAVA

Правка en1, от XDD_____, 2021-01-29 08:00:30

I was solving C in Div2 #698 and I have a query

105802847 and 105802880 are my submission the only difference is the line

if(a.get(i)-a.get(i-1)!=0){f=false;} and if(a.get(i)!=a.get(i-1)){f=false;}respectively

The first one got accepted while the second one fails the last tc of sample test

Please tell me why this is happening

Thanks.

Теги doubts

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en1 Английский XDD_____ 2021-01-29 08:00:30 427 Initial revision (published)