![]() |
.. (לתיקייה המכילה) | |
Q2, Are we allowed to use take or drop functions? | |
Yes you are. |
Q1.B, Can we use the solution of Q1.A? | |
No. Please solve Q1.A and Q1.B independently. |
How can we encapsulate private functions for the solution of questions 3 and 4? | |
you may do it in the following way: local (* private functions for question 2 *) (* private functions for question 3 *) (* private functions for question 2 and 3 *) in fun solveKnightTour ... fun checkKnightTour ... end Make sure that: 1, Code reuse- don't implement a function more then once. 2, Don't expose any auxiliary function. Only the functions you were asked to implement. |
Is it OK to submit code that have warnings? | |
Yes it is. As long as it will not throw exception for any legal input. |
What should the functions foldl and foldr return if [X1,..., Xn] list is empty? | |
They should return the received 'A' value. |
Q2, Are we allowed to use local auxiliary functions? | |
Yes you are. |
Q2, Are we allowed to use length function? | |
Yes you are. |
Q1, Are we allowed to use local auxiliary functions? | |
Yes you are but you don't need to. Try to solve it without auxiliary functions. |