Page 1 of 1

*** RESULT COMPETITION 2008 ***

Posted: Mon Nov 24, 2008 5:07 pm
by newdep
******************************************************************

We have a winner!


Thank you all for voting.. it was 4 to 3 for Cormullion vs Cyril
based on the votings we received..

Cormullion, you lucky bastard!, you got again a T-Shirt!

You can pick up you price at Lutz's house, have a coffee and
share the profiling thought ;-) Let us know how the tripp was..

(ps: tripp not included in the price)


Thank you all for your participation!

******************************************************************

Image











The competition is closed, please make your votes!
The winner gets the famous newlisp T-Shirt and 2008 winner fame!

The poll , above, stays for 5 days, counting from today.


Okidoki... Its was very short daylight for this year competition but still we have 2 very nice entry's.

Im not sure if setting pre-tasks as a good way to setup competitions but it was worth trying it and 2 nice contributions came in..!

... within the hour Cyril already posted his calendar contribution...;-)

Cyril and Cormullion are the contributers this year.
See below their code/link..












NEWLISP COMPETITION 2008


..Alright.. it seems people are starting to get a "coding-itch"..


This years competition is predefined and there is only 1 winner.



The code
- must be written in newlisp
- run on all (Linux/MacOS/Windows) newlisp binary's without modification.
- newlisp script must run out of the box, no modifications must be done by the user.
- newlisp script must contain coding comments by author
- compatible from 9.9.9.4 and up. (basicly is should be compatible for rel. 10)
- source code is released under the GNU license from newlisp.
- For the originality "dont borrow code"
- You may select one/many from the options below to participate.



(option #1) A newlisp code profiler

Code: Select all

A program/script that returns a profile of the analized newlisp-script. 

The profile result should at least contain:
Preformance information of the analized script.
Could have readability and coding enhancements

How you target your profiler is up to you, main issue is that it
returns valuable information regarding coding/content of the profiled-newlisp-script.

(option #2) A newlisp enhanced parenthesis checker

Code: Select all

A program/script that returns the exact position of the missing/extra paranthesis inside the checked newlisp-script. 
(The buildin newlisp intepreter isn't accurate enough, from my point of view, to point out "where" it went wrong..)

The paranthesis check should at least contain:
The exact position of where a paranthese is missing/extra. (line number + char position in that line).
Not check in strings ".." {..} [text]..[/text]
Not check data in comments. ; or #

How you target your paranthesis checker is up to you, 
main issue is that it returns accurate information regarding 
the paranthesis mismatch (missing/extra) inside the checked newlisp-script.

(option #3) A newlisp AI

Code: Select all

A program/script that demonstrates newlisp and Artificial Intelligence. 
Where the script must show its capebility to "learn" from data.
It must use FOOP.
User interaction and manual data-input-feeding is not allowed. (like a chat program)
Ofcourse you can provide data for learning purposes.
http://en.wikipedia.org/wiki/Artificial_intelligence
http://en.wikipedia.org/wiki/Machine_learning

How you target your AI is up to you, 
main issue is that it shows/demonstrates that it can "learn" from data. 

(option #4) A newlisp calendar

Code: Select all

A program/script should be able to return the name of the day of the given, any!, date as input. 
(where monday is the first day of the week).

The calendar should at least return:
The name of the day when entering any date i.e. (10/05/218 = dd/mm/yyyy) as input. 
(name of day is "Monday" "Tuesday" "Wednesday" "Thursday" "Friday" "Saturday" "Sunday")
(B.C. notation is mm/dd/-yyyy)
No external date tools are allowed, only newlisp code.


How you target your calendar is up to you, 
main issue is that it returns accurate information regarding 
the calendar day. Basicly its a  "start/endless" calendar.


Enjoy...


PS: questions/answers/suggestions/donations (koffie/beer/milk/cooky's) are welcome.


PPS:
-Competition ends 31st of December 2008 at (23:59:59)
-Please post your code/link befor the 31th of December in this Forum topic

Posted: Mon Nov 24, 2008 9:57 pm
by newdep
I had a question/answer minute with Lutz about the Contest content.
I added 3 more options just to make it more variable for the users.
A 'profiler' is very nice but im not sure if that would trigger enough
people to join in.. The other options should be able to tickle more people..

Hope you all agree...

Enjoy..

Posted: Mon Nov 24, 2008 10:36 pm
by cormullion
Excellent! I shall attempt to write one script that does all four at once...! :)

Post only on the 31st December? Mustn't plan to party that night...

Re: =(NEWLISP-COMPETITION 2008)=

Posted: Tue Nov 25, 2008 2:41 am
by Cyril
newdep wrote: (option #4) A newlisp calendar
Just to make the first entry:

Code: Select all

;; @module zeller.lsp
;; @description Straightforward implementation of Zeller's congruence
;; @author Cyril Slobin
;; @location http://slobin.pp.ru/newlisp/zeller.lsp
;; @version 2.0, corrected and updated
;;
;; See also @link http://en.wikipedia.org/wiki/Zeller%27s_congruence
;; Zeller's_congruence article in Wikipedia
;;
;; Date format on input as specified by newdep, <b>exactly</b>

; The week starts with Saturday, it's a feature of the algorithm used
(setq week '(Saturday Sunday Monday Tuesday Wednesday Thursday Friday))

; Modulo is not the same as reminder
(define (%% x y) (% (+ (% x y) y) y))

; Division with modulo-aware rounding
(define (// x y) (/ (- x (%% x y)) y))

; Zeller's congruence, verbatim
(define (zeller q m year , h J K)
  (when (member m '(1 2))
    (inc m 12)
    (dec year))
  (setq J (// year 100))
  (setq K (%% year 100))
  (setq h (+ q (// (* 26 (+ m 1)) 10) K (// K 4) (// J 4) (* -2 J)))
  (week (%% h 7)))

; Note that newdep specified dd/mm/yyyy for AC, but mm/dd/-yyyy for BC
(while (read-line)
  (map set '(aa bb year) (map int (parse (current-line) "/")))
  (case (sgn year)
    (0 (println "No zeroth year!"))
    (+1 (println (zeller aa bb year)))
    (-1 (println (zeller bb aa (+ year 1))))))

(exit)

Sorry, this is kinda practical joke, but it works nevertheless. ;-)

Oops! Updated to version 2.0, previous gives wrong answers B.C.

Posted: Tue Nov 25, 2008 7:28 am
by newdep
Your sorry is not accepted ;-) Nice coding and reading between the lines ;-)

Posted: Tue Nov 25, 2008 3:06 pm
by Cyril
newdep wrote:Your sorry is not accepted ;-) Nice coding and reading between the lines ;-)
Sorry nevertheless -- the first version was WRONG. The moral of that is, NEVER try to "optimize" formulae given to you by the astronomer! I am an amateur astronomer myself, I say this from experience! The post above was corrected for version 2.0, with hope it is right this time.

Posted: Tue Nov 25, 2008 3:32 pm
by Kazimir Majorinc
I might enter in AI class if it is allowed to bend rules somehow, i.e. that major part of the program is written in old fashioned procedural imperative style, but I can still use FOOP for some minor issue.

Is it acceptable compromise?

Posted: Tue Nov 25, 2008 4:18 pm
by newdep
If you clearly outline what is different from the rules inside your code,
(i.e. in your case: not using FOOP)
I think people won't mind you coding it ;-)

FOOP seems to be a nice base for this but if your code can
do without...no problem with me....

Posted: Wed Dec 17, 2008 5:28 pm
by cormullion
My entry is posted/described here:

http://www.alh.net/newlisp/phpbb/viewtopic.php?p=14436

It's a simple newLISP script profiler, called mycroft.

Posted: Tue Dec 30, 2008 11:49 pm
by newdep
--- 1 DAY TO GO ---

Posted: Wed Dec 31, 2008 1:53 am
by m i c h a e l
One day left?! There is no way I can deform any of my scripts to fit within the contest rules that quickly, but it was making me sad seeing cormullion standing there proudly holding his contest entry all alone :-( But since mycroft is so cool, anyway, he probably has it in the bag this year ;-)

Happy 2009 to the entire newLISP community! I'm anxious to see what fantastic things are in store for our favorite language.

m i c h a e l

Posted: Wed Dec 31, 2008 6:34 am
by Kazimir Majorinc
I didn't completed application I intended to write, so I'll also give up this year.

Posted: Wed Dec 31, 2008 11:27 pm
by newdep


*** HAPPY 2009 ***

May The Lisp be with you! ;-)


Posted: Thu Jan 01, 2009 11:25 pm
by cormullion
nothing from you norman? Ah well, you have a good excuse! :(

Perhaps announce the 2009 contest soon - give everyone more time! :)

Posted: Fri Jan 02, 2009 12:52 am
by m i c h a e l
In my above post, I unintentionally ignored Cyril, who, having arrived early, was quietly sitting on the stage waiting for the winner to be announced.

Cyril, please forgive my having forgotten your worthy entry.
Norman wrote:Im not sure if setting pre-tasks as a good way to setup competitions but it was worth trying it and 2 nice contributions came in..!
Maybe the pre-tasks would have worked better with a larger group of active members, but with such a small group here, I’m afraid it may have hindered participation. Cyril’s and cormullion’s entries are proof it was worth a try, though.

m i c h a e l

Posted: Fri Jan 02, 2009 7:16 am
by newdep
cormullion wrote:nothing from you norman? Ah well, you have a good excuse! :(

Perhaps announce the 2009 contest soon - give everyone more time! :)

Yeah i know , i dislike it too!... I had the full intention to drop in with the parenthesis checker 80% finished and some AI... but man last weeks
where so bussy I could not do any completion on my tools...

I think we should do next years competition like "pick the nicest newlisp
application you can find..." that would include any application build over the
years... but thats perhpas for next year...

Yeah..your lucky I did not join in btw ;-)

Posted: Fri Jan 02, 2009 9:33 am
by cormullion
newdep wrote:Yeah..your lucky I did not join in btw ;-)
True! :) I bribed the others to stay away... :)

Posted: Tue Jan 06, 2009 1:59 pm
by newdep
we have a winner!

Posted: Tue Jan 06, 2009 7:01 pm
by cormullion
Wow, I've won something! :) Thanks everyone. Although I can't help thinking that it would have been even better to have lost out to 25 amazing contributions from others...

I still have no idea whether my entry actually works... mixing newLISP, newLISPdoc, HTML, and CSS in one file makes my head hurt. :)

Thanks again!

Posted: Tue Jan 06, 2009 7:47 pm
by newdep
Well there are at least 4 people who tested you application..
..the voters I may asume ;-)..

But never the less ill be testing it on my new OS/2 release as your application is a nice test case on newlisp, covers a lot indeed ;-)