[S] worked on nim. added changes to NIM docs.

This commit is contained in:
eline
2023-11-29 13:37:44 +01:00
parent e774316a70
commit 59512d7b64
6 changed files with 135 additions and 74 deletions

View File

@@ -20,12 +20,14 @@ proc MessageBox*(hWnd: HWND, lpText: LPCSTR, lpCaption: LPCSTR, uType: UINT): in
var
titlemessages = @["Are you really free?",
"Window on the street, only mesmerized and pondering... Am I in the right?"]
captionmessages = @["From the river to the sea, Palestine will be free.",
"I believe and have faith in you."]
"Poland!"]
captionmessages = @["From the river to the sea, Palestine will be free.", "We are the people of Heaven.",
"War is peace. Slavery is freedom. Ignorance is strength.","Kurva mac!"] # todo: convert to cstrings
randomize() # seeds randomizer
var
randomtitle:string = sample(titlemessages)
randommessage:string = sample(captionmessages)
var
randomtitle:cstring = sample(titlemessages).cstring
randommessage:cstring = sample(captionmessages).cstring
if isMainModule:
MessageBox(0, randomtitle, randommessage, 0)