output at the terminal should look like : noTriples({1, 1, 2, 2, 1}) -> true
noTriples({1, 1, 2, 2, 2, 1}) -> false
Basically there should be no triples in the code. if there are any, it returns...
Type: Posts; User: hemla
output at the terminal should look like : noTriples({1, 1, 2, 2, 1}) -> true
noTriples({1, 1, 2, 2, 2, 1}) -> false
Basically there should be no triples in the code. if there are any, it returns...
for (i = 0; i < numbers.length - 2; i++)
In some codes we write i<numbers.length and in some numbers.length-1 or some others. What does this piece of code actually mean?