Random commentary about Machine Learning, BigData, Spark, Deep Learning, C++, STL, Boost, Perl, Python, Algorithms, Problem Solving and Web Search
queue queque.in(a[0])int length = 1foreach a[i] i > 0{ if a[i] >= que.last { length++ } else { if length > que.length { que.clearall for j = 0 to lentgh que.in(a[i - j]) } length = 0 }}
queue que
ReplyDeleteque.in(a[0])
int length = 1
foreach a[i] i > 0
{
if a[i] >= que.last
{
length++
}
else
{
if length > que.length
{
que.clearall
for j = 0 to lentgh
que.in(a[i - j])
}
length = 0
}
}
queue que
ReplyDeleteque.in(a[0])
int length = 1
foreach a[i] i > 0
{
if a[i] >= que.last
{
length++
}
else
{
if length > que.length
{
que.clearall
for j = 0 to lentgh
que.in(a[i - j])
}
length = 0
}
}