Capital Cities Tester
Re: Capital Cities Tester
Morning all, the online emulators work with tap, z80 and sna files.
Peter
PS. JSSpeccy apparently works with some tzx files, but that is undergoing testing currently by us.
Peter
PS. JSSpeccy apparently works with some tzx files, but that is undergoing testing currently by us.
Re: Capital Cities Tester
Nice!
Out of curiosity, what wast he source for your list of states and capitals? Did you include some really small states like Kiribati or Marshall Islands? And what about controversial states not accepted by everyone?
Out of curiosity, what wast he source for your list of states and capitals? Did you include some really small states like Kiribati or Marshall Islands? And what about controversial states not accepted by everyone?
Re: Capital Cities Tester
I took this list, one of the first in a usable format thrown up by a google search.
So that ignores various 'areas of complexity' , Cyprus is only the Republic of, I added Palestine with Ramallah as de facto capital, I removed some of the smallest islands (possibly Marshall Island and Kiribati included). I can't remember all the details but in the cold light of day I'm worried I didn't give these decisions enough consideration.
Now, who *haven't* I pissed off?
- Juan F. Ramirez
- Bugaboo
- Posts: 5137
- Joined: Tue Nov 14, 2017 6:55 am
- Location: Málaga, Spain
Re: Capital Cities Tester
At last, after 35 years, a program that help us with our homework!
*gets coat etc*
*gets coat etc*
Re: Capital Cities Tester
Oh bloody hell! It's missing Northern Ireland
A fixed version will be in the next update
A fixed version will be in the next update
Re: Capital Cities Tester
AAh, that's why I got 'plank' (I'm from the capital of NI)!
Everyone else was playing with an advantage.
Everyone else was playing with an advantage.
Re: Capital Cities Tester
I think you were the reason I remembered, norniron must have sprung to mind.
Dammit, I still need to add the rest of CGC 2013 files to the site, here it is for now.
Dammit, I still need to add the rest of CGC 2013 files to the site, here it is for now.
Re: Capital Cities Tester
How about historical states? But then that is a whole new can of worms. Like what do you do when a government is in a state of collapse like say Italy at the end of the second world war.. Or Manchukuo, that changed its capital twice and now is a non-existent state...
Re: Capital Cities Tester
We could have a fantasy future version too, for example in John Wyndham's 'The Kraken Awakes' in which Harrogate becomes the capital when the undersea aliens melt the icecaps and flood London (or something like that).
The DATA string search is already too long for BASIC though. If you play the list game you'll notice it get gradually slower as it steps through the alphabet, by the time you're at Zimbabwe you can make a cup of tea* in the time it takes to find the string and print the yx cors. I'm too busy with other stuff but I did toy with the idea of a machine code version that included a summary of the country - population, currency etc and its flag.
*maybe not, but there's time enough to send a text while jiggling your legs.
The DATA string search is already too long for BASIC though. If you play the list game you'll notice it get gradually slower as it steps through the alphabet, by the time you're at Zimbabwe you can make a cup of tea* in the time it takes to find the string and print the yx cors. I'm too busy with other stuff but I did toy with the idea of a machine code version that included a summary of the country - population, currency etc and its flag.
*maybe not, but there's time enough to send a text while jiggling your legs.
Re: Capital Cities Tester
If you wanted to optimize it some, you could get the first letter in, say, A, then RESTORE 1000+10*A so you only have to search through words with the same first letter.
[EDIT]
Looking at the code, you'd be much better off just having each country on a single line:
100 DATA "Afghanistan", "Agfa Albion", 13, 10
101 DATA "Algeria", "Algerton", 11, 14
Then you wouldn't need to loop at all.
You could just RESTORE 100+country: READ a$,b$,x,y
[EDIT]
Looking at the code, you'd be much better off just having each country on a single line:
100 DATA "Afghanistan", "Agfa Albion", 13, 10
101 DATA "Algeria", "Algerton", 11, 14
Then you wouldn't need to loop at all.
You could just RESTORE 100+country: READ a$,b$,x,y
Re: Capital Cities Tester
Oh that's much better, and a good way of allowing alternative strings for "St" and "Saint" etc. Cheers!Kweepa wrote: ↑Sun May 06, 2018 10:55 pm Looking at the code, you'd be much better off just having each country on a single line:
100 DATA "Afghanistan", "Agfa Albion", 13, 10
101 DATA "Algeria", "Algerton", 11, 14
Then you wouldn't need to loop at all.
You could just RESTORE 100+country: READ a$,b$,x,y
I might even be charitable and give "ULAANBAATAR" alternatives, AFAIK this is correct spelling, but a lot of people expect the anglicised "ULAN BATOR".
Re: Capital Cities Tester
I've made some improvements thanks to suggestions from Kweepa, which have allowed more scope for alternative spellings (Washington DC/Washington D.C., Nay Pyi Taw/Naypyidaw...). It will now find every country very quickly and the same speed regardless of the first letter, I'm actually embarrassed my first attempt had such an appalling way of READing the data
And I've added Northern Ireland!
I seem to be floating around the 45% mark, I permanently walk round in the hope that someone will randomly ask me what the capital of Burkina Faso is.
As the next update will be next week, DOWNLOAD here for now.
And I've added Northern Ireland!
I seem to be floating around the 45% mark, I permanently walk round in the hope that someone will randomly ask me what the capital of Burkina Faso is.
Spoiler
Ouagadougou!
- MatGubbins
- Dynamite Dan
- Posts: 1239
- Joined: Mon Nov 13, 2017 11:45 am
- Location: Kent, UK
Re: Capital Cities Tester
Very nice and a lot faster. I'm still a plank.
Just a very small request.... Can we have a Currah Microspeech version that asks the questions, and speaks the answers and pronounces them correctly?
Just a very small request.... Can we have a Currah Microspeech version that asks the questions, and speaks the answers and pronounces them correctly?
Re: Capital Cities Tester
That is a brilliant idea. I only used currah in a couple of games and have never developed with it, I assume it's possible here.MatGubbins wrote: ↑Thu May 17, 2018 11:48 pm Can we have a Currah Microspeech version that asks the questions, and speaks the answers and pronounces them correctly?
Re: Capital Cities Tester
Good shout, it's always nicer to be called a buffoon via the spoken (rather than written) word...
My Speccy site: thirdharmoniser.com
- MatGubbins
- Dynamite Dan
- Posts: 1239
- Joined: Mon Nov 13, 2017 11:45 am
- Location: Kent, UK
Re: Capital Cities Tester
Currah only works with 48k Spectrums.
PAUSE 1 is your friend.
PAUSE 1 is your friend.
Re: Capital Cities Tester
Is it really not possible to get the Microspeech to work with 128K machines? I might be remembering this wrong but I thought it just replaced the standard BASIC interrupt routine and paged in its own ROM at address 56, which output the contents of a buffer at the top of memory. So what if this routine was somehow bypassed and instead the allophones were just output directly to the hardware?
I suppose the problem would be how to page in the ROM to get at the allophone table without needing the interrupt routine to be running. On the +3 you can have RAM where the ROM normally is, so would that help?
I suppose the problem would be how to page in the ROM to get at the allophone table without needing the interrupt routine to be running. On the +3 you can have RAM where the ROM normally is, so would that help?