You mean: cost([1,4,5,3,2]) = 1
Is that it? mostafa eslahi escreveu: > Thanks for paying attention... > Indeed, My cost function is like this: > I want to count number of consecutive element of a array(1*n) that it's > elements are distinct numbers of set [1..n]. > could you help me? > Cheers. > > > --------------------------------- > Be smarter than spam. See how smart SpamGuard is at giving junk email the > boot with the All-new Yahoo! Mail > _________________________________________________________________________________ > mozart-users mailing list > [email protected] > http://www.mozart-oz.org/mailman/listinfo/mozart-users Jorge M. Pelizzoni ICMC - Universidade de São Paulo _________________________________________________________________________________ mozart-users mailing list [email protected] http://www.mozart-oz.org/mailman/listinfo/mozart-users
