Author Topic: chess engine  (Read 1064 times)

jj2007

  • Member
  • *****
  • Posts: 9687
  • Assembler is fun ;-)
    • MasmBasic
Re: chess engine
« Reply #15 on: July 14, 2019, 07:50:48 PM »
And you show a double quote at the start of each line, only God knows why.

That's a bug indeed, I'll have to investigate. The rest is nonsense.

P.S.: That WHO csv file is kind of malformed, as it uses quotes where there is no need for quotes. If you open it in Excel and save it, the quotes will be removed.

In MasmBasic, there is a simple workaround: A Csv2Tab right after the Recall. Works perfect.

As always, csv is a can of worms.
« Last Edit: July 15, 2019, 12:21:57 AM by jj2007 »

AW

  • Member
  • *****
  • Posts: 2316
  • Let's Make ASM Great Again!
Re: chess engine
« Reply #16 on: July 15, 2019, 12:24:30 AM »
The rest is nonsense.
It's common sense, but that's OK  :thumbsup:. Note that with Powershell you can do it, and even change the table titles:

Code: [Select]
$desiredColumns = 'country','year', 'e_rr_pct_new','e_rr_pct_new_lo','e_rr_pct_new_hi','e_mdr_pct_rr_new','source_rr_ret','source_drs_coverage_ret'
$web = New-Object Net.WebClient
$web.DownloadString("https://extranet.who.int/tme/generateCSV.asp?ds=mdr_estimates") | ConvertFrom-Csv | Select $desiredColumns | Format-Table -AutoSize Country, Year, @{L=’Header1’;E={$_.e_rr_pct_new}}, @{L=’Header2’;E={$_.e_rr_pct_new_lo}}, @{L=’Header3’;E={$_.e_rr_pct_new_hi}},@{L=’Header4’;E={$_.e_mdr_pct_rr_new}},@{L=’Header5’;E={$_.source_rr_ret}},@{L=’Header6’;E={$_.source_drs_coverage_ret}}

Output:

Code: [Select]
country                                              year Header1 Header2 Header3 Header4 Header5      Header6
-------                                              ---- ------- ------- ------- ------- -------      -------
Afghanistan                                          2017 3.7     2       5.9     79      Model
Albania                                              2017 2.3     0.64    5.8     100     Surveillance National
Algeria                                              2017 2.5     1.1     4.3     67      Model
American Samoa                                       2017 2.3     0.86    4.4     78      Model
Andorra                                              2017 0       0       98      100     Surveillance National
Angola                                               2017 2.5     1.1     4.3     67      Model
Anguilla                                             2017 2.3     0.79    4.5     83      Model
Antigua and Barbuda                                  2017 2.3     0.79    4.5     83      Model
Argentina                                            2017 2.3     1.3     3.8     94      Survey       National
......
United Kingdom of Great Britain and Northern Ireland 2017 1.4     0.93    2       86      Surveillance National
United Republic of Tanzania                          2017 0.9     0.3     1.5     100     Survey       National
......
Zambia                                               2017 1.1     0.34    2.3     27      Survey       National
Zimbabwe                                             2017 4.6     3       6.2     39      Survey       National

AW

  • Member
  • *****
  • Posts: 2316
  • Let's Make ASM Great Again!
Re: chess engine
« Reply #17 on: July 15, 2019, 12:49:59 AM »
P.S.: That WHO csv file is kind of malformed, as it uses quotes where there is no need for quotes. If you open it in Excel and save it, the quotes will be removed.

You can only insert the double quotes when they are escaped, i.e, if you have 3 double quotes in a row.

jj2007

  • Member
  • *****
  • Posts: 9687
  • Assembler is fun ;-)
    • MasmBasic
Re: chess engine
« Reply #18 on: July 15, 2019, 01:07:24 AM »
If you like this kind of stuff, try this UN database. Line 42257, for example (WB Staff estimates) is interesting. The correct decoding of column 1 would be

Code: [Select]
WB Staff estimates. Cambodia Poverty Assessment 2013 "Where Have All The Poor Gone?",  May 2013. Cambodia Socio-Economic Survey 2009.

AW

  • Member
  • *****
  • Posts: 2316
  • Let's Make ASM Great Again!
Re: chess engine
« Reply #19 on: July 15, 2019, 01:44:21 AM »
If you like this kind of stuff, try this UN database. Line 42257, for example (WB Staff estimates) is interesting. The correct decoding of column 1 would be

Code: [Select]
WB Staff estimates. Cambodia Poverty Assessment 2013 "Where Have All The Poor Gone?",  May 2013. Cambodia Socio-Economic Survey 2009.

All right, the UN database does not appear to conform to common practices.
However, the WHO.INT does appear to conform, they use double quotes even when not needed but there is nothing wrong with that.

daydreamer

  • Member
  • ****
  • Posts: 907
  • watch Chebyshev on the backside of the Moon
Re: chess engine
« Reply #20 on: July 27, 2019, 07:35:48 PM »
thanks for showing me ways of make .exe smaller with help of fetch data from website ala Java applet way JJ&AW

so far chessboard can be made with 33 rects but also 33 2D polys are prefered because you can draw a pseudo3d chessboard chesspieces can be made with GDI 2Dpolys or ellipses&lines,trouble with make knights look good
later it maybe possible to make with 3dmeshes,could be nice to have Marinus advice on this
Quote from Flashdance
Nick  :  When you give up your dream, you die
*wears a flameproof asbestos suit*
Gone serverside programming p:  :D

daydreamer

  • Member
  • ****
  • Posts: 907
  • watch Chebyshev on the backside of the Moon
Re: chess engine
« Reply #21 on: August 06, 2019, 02:11:06 AM »
havent got so far,3dmeshcreator unfinished
included some unfinished meshes as well
« Last Edit: August 07, 2019, 04:31:24 AM by daydreamer »
Quote from Flashdance
Nick  :  When you give up your dream, you die
*wears a flameproof asbestos suit*
Gone serverside programming p:  :D