00:00:00 --- log: started forth/10.03.21 00:28:03 --- join: ygrek (debian-tor@gateway/tor-sasl/ygrek) joined #forth 00:36:28 --- quit: proteusguy (Ping timeout: 276 seconds) 00:49:15 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 01:00:31 --- quit: tgunr (Ping timeout: 276 seconds) 01:21:16 --- join: qFox (~C00K13S@5356B263.cable.casema.nl) joined #forth 01:56:41 --- quit: gogonkt (Ping timeout: 256 seconds) 01:58:36 --- join: gogonkt (~info@218.13.52.133) joined #forth 02:46:02 --- quit: proteusguy (Ping timeout: 248 seconds) 02:59:50 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 04:50:18 --- quit: proteusguy (Ping timeout: 258 seconds) 05:00:59 --- join: kar8nga (~kar8nga@jol13-1-82-66-176-74.fbx.proxad.net) joined #forth 05:03:03 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 05:49:18 --- quit: kar8nga (Remote host closed the connection) 05:58:05 --- quit: gogonkt (Ping timeout: 256 seconds) 05:59:57 --- join: gogonkt (~info@121.9.179.149) joined #forth 06:12:59 --- join: johnl_ (~johnl@217.78.4.44) joined #forth 06:15:50 --- quit: saper_ (Changing host) 06:15:50 --- join: saper_ (saper@wikipedia/saper) joined #forth 06:15:55 --- nick: saper_ -> saper 06:54:59 --- quit: proteusguy (Ping timeout: 260 seconds) 07:07:24 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 07:22:47 --- quit: X-Scale (Ping timeout: 260 seconds) 07:47:20 --- join: kar8nga (~kar8nga@jol13-1-82-66-176-74.fbx.proxad.net) joined #forth 08:08:13 --- quit: proteusguy (Ping timeout: 276 seconds) 08:19:45 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 08:48:54 --- join: impomatic (~John@87.113.186.178) joined #forth 09:34:48 --- quit: proteusguy (Ping timeout: 252 seconds) 09:38:02 Does anyone use a programmer's editor to write Forth code? 09:47:42 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 10:14:03 --- quit: schmx (Ping timeout: 240 seconds) 10:14:06 --- join: schmx (~marcus@sxemacs/devel/schme) joined #forth 10:32:04 --- join: fitnerd (~dan@97-118-162-242.hlrn.qwest.net) joined #forth 11:17:58 --- quit: ygrek (Remote host closed the connection) 11:19:19 --- join: ygrek (debian-tor@gateway/tor-sasl/ygrek) joined #forth 11:35:55 --- quit: probonono (Ping timeout: 260 seconds) 11:38:03 --- join: probonono (~User@unaffiliated/probonono) joined #forth 11:38:30 --- quit: proteusguy (Ping timeout: 276 seconds) 11:38:45 impomatic: Yes. 11:41:05 ASau: which do you prefer? 11:41:21 Emacs. 11:41:52 Hmmm... everyone seem to use Emacs or Vim. 11:44:34 not everyone :) 11:44:38 --- nick: crc_ -> crc 11:48:11 kwrite! 11:48:32 --- join: boscop_ (~boscop@f050133169.adsl.alicedsl.de) joined #forth 11:49:08 nano 11:50:07 --- quit: boscop (Ping timeout: 246 seconds) 11:50:22 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 12:11:18 --- join: segher (~segher@84-105-60-153.cable.quicknet.nl) joined #forth 12:24:33 --- join: zzo38 (~zzo38@h24-207-48-53.dlt.dccnet.com) joined #forth 12:24:47 What is the best way to generate a random number 0..51 in Gforth? 12:25:12 52 random 12:26:03 Oh, well. It's my own thing. 12:26:06 Thanks 12:26:22 You have to implement PRNG. 12:26:28 That appears to work now I have to test it in my program because it shuffle a deck of cards 12:27:24 Just REQUIRE random.fs will make that command available 12:27:37 In this game only the suits are relevant though 12:28:06 Ah. 12:28:10 What is the best way to seed the random number generator? I used TIME&DATE + + + + + SEED ! but is there a better way 12:29:20 Well... It is LCG. 12:29:40 What does LCG means? 12:29:52 Linear congruential generator. 12:30:08 Surely there must be a better way to seed the random number generator. 12:30:12 Of the most primitive kind. 12:30:31 Using HERE like was seen on some other web-page, doesn't work, because I get the same number every time 12:30:33 Very nice story about seeding RNG is debi-an black tuesday. 12:31:02 Sorry, I don't understand you? 12:31:37 The story how they broke openssl rng seeding and endangered many of their users. 12:31:55 by making all security keys essentially insecure. 12:32:14 Now I understand. For cryptography, you need a cryptographically secure random number generator, of course. 12:32:27 But I'm not doing cryptography I'm simply shuffling a deck of cards 12:32:46 Tell that to casino systems programmers. :) 12:33:37 Yes, in a casino it is different because of money involved 12:34:16 In a casino I would use noise source for random numbers to ensure proper randomness 12:34:36 I think that FFI call to srandom and random give you better RNG. 12:35:01 And even in cryptography, if the randomness need not be repeatable I would even make it use noise source if one is available 12:35:06 On BSDs it uses a bit better algorithm. 12:35:08 What is FFI call? 12:35:18 foreign function interface. 12:40:31 There is my program: http://pastebin.ca/raw/1848449 Tell me if there is something wrong or if you have other suggestion/comment, etc. So far I have tested it only on Windows but it should work for Linux also, hopefully 12:43:44 ESCAPE: [31;1m RED 12:43:50 NEVER EVER DO THIS SHIT. 12:44:21 And why do you think that, in your opinion 12:44:30 This violates rules and thus it doesn't work. 12:44:43 It does work I tested it. 12:45:06 Tests don't prove that code doesn't have bugs. 12:45:17 This truth is known for half a century. 12:45:29 Yes at least that part is true. 12:45:51 If it is wrong, what part of it has a bug 12:46:27 ESC "[31;1m" just sends ESC and "[31;1m". 12:47:03 You can see _all_ output, including ^[ for escape symbol. 12:47:24 You don't test terminal settings. 12:48:17 O, it is because I didn't test terminal settings? 12:48:40 Yes, and the terminal I use for testing doesn't support this. 12:49:03 Sorry. What terminal are you using? 12:49:59 tset -r 12:49:59 Terminal type is emacs. 12:49:59 Erase is . 12:49:59 Kill is . 12:52:17 If you use cells to store essentially non-letters, you can make it more clear. 12:52:26 There's common contraction 12:52:31 : th cells + ; 12:52:49 OK, thanks 12:53:26 Except I use CHARS + in my program but not CELLS + 12:53:53 Why do you CHARS to access essentially non-symbolic data? 12:54:09 To save memory 12:54:23 CHARS may be synonymous to CELLS. 12:54:29 This doesn't save memory. 12:55:11 I tried it and it isn't. On which computers is it synonymous to CELLS at least on my computer it isn't 12:55:22 On my Gforth sometimes it is. 12:55:31 Only sometimes? 12:55:49 Yes, I redefine it for some tasks. 12:56:11 In any case, you ought not to "save memory" by using inappropriate means. 12:56:19 OK, now I can understand. But this program won't redefine it 12:56:30 If you want to save memory, you don't use gforth. 12:56:45 OK, I can understand that 12:57:54 --- join: scj (syljo361@static-ip-62-75-255-125.inaddr.server4you.de) joined #forth 12:59:57 The URL at the top of the file contains instructions for the game 13:00:17 I mean the URL points to contain instruction for game 13:10:56 --- quit: kar8nga (Remote host closed the connection) 13:11:00 zzo38: http://forth.pastebin.com/ZZSR1CfN 13:11:07 With comments. 13:11:17 --- join: kar8nga (~kar8nga@jol13-1-82-66-176-74.fbx.proxad.net) joined #forth 13:11:17 OK 13:11:45 see "COMMENT:" marks. I tried to make it more visible. 13:12:25 Thanks for telling all the comments. There are many things I didn't know about it but now I can learn. 13:13:24 See "AT-XY". 13:14:04 Gforth is broken, esp. 0.7.0, but at least you can hope 13:14:05 that someone fixes AT-XY so that it does work properly. 13:44:27 --- join: Arac (~D@80-121-49-20.adsl.highway.telekom.at) joined #forth 13:50:06 --- join: crc_ (~charlesch@71.23.210.149) joined #forth 13:51:06 --- quit: proteusguy (Ping timeout: 248 seconds) 13:54:01 --- quit: crc (Ping timeout: 276 seconds) 13:55:36 --- quit: fitnerd (Quit: fitnerd) 14:00:07 --- quit: zzo38 (Remote host closed the connection) 14:03:34 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 14:07:32 --- quit: madwork (Ping timeout: 245 seconds) 14:16:17 --- nick: boscop_ -> boscop 14:23:59 --- join: madwork (~madgarden@204.138.110.15) joined #forth 14:38:25 --- join: fitnerd (~dan@c-174-51-14-174.hsd1.co.comcast.net) joined #forth 14:38:41 --- quit: fitnerd (Client Quit) 14:42:35 --- quit: impomatic (Quit: mov.i #1,1) 14:55:48 --- quit: qFox (Quit: Time for cookies!) 14:56:16 --- quit: kar8nga (Remote host closed the connection) 15:03:59 --- join: Quartus` (~Quartus`@74.198.8.57) joined #forth 15:09:32 --- join: TR2N (email@89-180-180-247.net.novis.pt) joined #forth 15:11:51 --- join: Arach (~D@80-121-1-22.adsl.highway.telekom.at) joined #forth 15:15:02 --- quit: Arac (Ping timeout: 245 seconds) 15:19:46 --- quit: proteusguy (Ping timeout: 240 seconds) 15:31:21 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 16:19:37 --- quit: ygrek (Ping timeout: 245 seconds) 16:43:15 --- quit: Deformative (Ping timeout: 252 seconds) 16:44:20 --- quit: Arach (Quit: Cya later) 16:44:58 --- quit: proteusguy (Ping timeout: 276 seconds) 16:56:31 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 17:32:09 --- quit: Snoopy_1611 () 17:35:31 --- join: Snoopy_1611 (Snoopy_161@dslb-084-059-120-012.pools.arcor-ip.net) joined #forth 18:10:52 --- quit: proteusguy (Ping timeout: 245 seconds) 18:24:24 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 19:16:08 --- join: skas (~skas@eth488.act.adsl.internode.on.net) joined #forth 19:19:17 --- join: Deformative (~joe@bursley-185022.reshall.umich.edu) joined #forth 19:39:30 --- quit: proteusguy (Ping timeout: 276 seconds) 19:44:42 --- quit: Quartus` (Ping timeout: 276 seconds) 19:51:34 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 20:20:33 --- quit: proteusguy (Ping timeout: 256 seconds) 20:34:01 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 20:49:54 --- join: cataska (~cataska@210.64.6.233) joined #forth 21:47:53 --- quit: jabb (Quit: bbl) 21:47:58 --- quit: proteusguy (Ping timeout: 246 seconds) 22:00:07 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 23:00:22 --- quit: proteusguy (Ping timeout: 246 seconds) 23:13:05 --- join: nighty (~nighty@x122091.ppp.asahi-net.or.jp) joined #forth 23:13:40 --- quit: skas (Quit: Leaving) 23:13:43 --- quit: nighty (Client Quit) 23:13:50 --- join: proteusguy (~proteusgu@zeppelin.proteus-tech.com) joined #forth 23:59:59 --- log: ended forth/10.03.21