Sponsored Content
The Lounge What is on Your Mind? Debugging Our Computer Science Trivia Feature Post 303040642 by Neo on Sunday 3rd of November 2019 01:50:19 AM
Old 11-03-2019
Also, so far unregistered guests from all over the world (86 to date, actually 85+ since the XX country entry contains the unknown entries) have answered trivia questions, with the US, India, Great Britain, Germany, Brazil, Italy, the Netherlands, and the Philippines all with over 100 DB submissions.

My plan is build some cool scoreboards and leaderboards later this month, when we have over 10,000 submissions.

Code:
mysql> select country, count(country) from neo_trivia_scoreboard where uid <1 group by country order by count(country) desc;
+---------+----------------+
| country | count(country) |
+---------+----------------+
| US      |            920 |
| IN      |            496 |
| GB      |            180 |
| DE      |            166 |
| BR      |            129 |
| IT      |            127 |
| NL      |            116 |
| PH      |            109 |
| FR      |             98 |
| AU      |             88 |
| CA      |             79 |
| RU      |             74 |
| AR      |             64 |
| PL      |             62 |
| ES      |             56 |
| UA      |             51 |
| CH      |             44 |
| FI      |             43 |
| MX      |             39 |
| SE      |             39 |
| ID      |             36 |
| HU      |             34 |
| XX      |             28 |
| BG      |             27 |
| TH      |             23 |
| RO      |             22 |
| BE      |             21 |
| AT      |             18 |
| ZA      |             18 |
| PK      |             13 |
| HK      |             13 |
| GR      |             11 |
| VN      |             10 |
| RS      |             10 |
| CL      |             10 |
| DK      |              9 |
| CZ      |              9 |
| VE      |              8 |
| TW      |              8 |
| PY      |              8 |
| MY      |              7 |
| IL      |              7 |
| SG      |              7 |
| IE      |              6 |
| SD      |              6 |
| CO      |              5 |
| SK      |              5 |
| NZ      |              4 |
| NO      |              4 |
| TR      |              4 |
| UY      |              4 |
| CN      |              4 |
| BA      |              3 |
| LU      |              3 |
| CR      |              3 |
| MA      |              3 |
| RW      |              3 |
| AP      |              3 |
| SI      |              2 |
| EU      |              2 |
| KE      |              2 |
| BB      |              2 |
| EE      |              2 |
| EC      |              2 |
| IS      |              2 |
| MD      |              2 |
| PT      |              2 |
| AM      |              1 |
| SA      |              1 |
| PR      |              1 |
| GT      |              1 |
| JP      |              1 |
| GN      |              1 |
| PA      |              1 |
| NA      |              1 |
| IR      |              1 |
| MK      |              1 |
| GE      |              1 |
| CY      |              1 |
| HR      |              1 |
| ET      |              1 |
| AE      |              1 |
| DO      |              1 |
| KZ      |              1 |
| SV      |              1 |
| KR      |              1 |
+---------+----------------+
86 rows in set (0.00 sec)

 

7 More Discussions You Might Find Interesting

1. What is on Your Mind?

Computer Science and Information Technology

Hi, I haven't posted on the forums for a while now, I tried to find the most appropriate section for this post, but if this is in the wrong section please forgive me. First, let me say I'm a sophomore in HS. I know that job wise I definitely want to do something in computers. A while ago I was... (5 Replies)
Discussion started by: hpicracing
5 Replies

2. Programming

Is Web Development is a part of computer science ?

I am now a student in university in 2nd year. I am studying computer science. But I am not sure what type of jobs computer science provide. I know some of them are software programming or network management. Recently, I hear some about Web Development. I wonder if it is a part of computer science.... (1 Reply)
Discussion started by: Anna Hussie
1 Replies

3. Web Development

Is Web Development is a part of computer science ?

I am now a student in university in 2nd year. I am studying computer science. But I am not sure what type of jobs computer science provide. I know some of them are software programming or network management. Recently, I hear some about Web Development. I wonder if it is a part of computer... (3 Replies)
Discussion started by: Anna Hussie
3 Replies

4. What is on Your Mind?

Forum Trivial Pursuit - New Computer Science and Mathematics Trivia for UNIX.com

I have added a new experimental "Computer Science and Mathematics Trivia - True or False" section in the discussions, currently under the tags box. In the future, I plan to Expand this feature to add more trivia categories from math, science and technology. Keep track of correct and... (20 Replies)
Discussion started by: Neo
20 Replies

5. What is on Your Mind?

1000+ Computer Science Trivia Questions at UNIX.COM

The UNIX and Linux Forums now has over 1000 TRUE / FALSE computer science and computer related trivia question in our database. These questions are of relatively high quality (compared to similar sites on the web) and are fun (according to feedback by users). In the first week during the... (1 Reply)
Discussion started by: Neo
1 Replies

6. What is on Your Mind?

New Member and Country Computer Trivia Leaderboards

Thanks to Akshay, who helped me write the core MySQL queries, we now have two new draft leaderboards, by (1) member and by (2) country: https://www.unix.com/trivia_stats.php Currently milhan leads the members with a high score of 90%: ... (3 Replies)
Discussion started by: Neo
3 Replies

7. What is on Your Mind?

Computer Trivia Feature Tops 50,000 Questions Answered

Just noticed that our successful computer trivia feature (stats here) has surpassed over 50,000 questions answered by users: https://www.unix.com/trivia_stats.php This was a coding effort worth while and I'm pleased to see so many people enjoying it in such a short time since it was released... (3 Replies)
Discussion started by: Neo
3 Replies
GEOIP_COUNTRY_CODE3_BY_NAME(3)						 1					    GEOIP_COUNTRY_CODE3_BY_NAME(3)

geoip_country_code3_by_name - Get the three letter country code

SYNOPSIS
string geoip_country_code3_by_name (string $hostname) DESCRIPTION
The geoip_country_code3_by_name(3) function will return the three letter country code corresponding to a hostname or an IP address. PARAMETERS
o $hostname - The hostname or IP address whose location is to be looked-up. RETURN VALUES
Returns the three letter country code on success, or FALSE if the address cannot be found in the database. EXAMPLES
Example #1 A geoip_country_code3_by_name(3) example This will print where the host example.com is located. <?php $country = geoip_country_code3_by_name('www.example.com'); if ($country) { echo 'This host is located in: ' . $country; } ?> The above example will output: This host is located in: USA SEE ALSO
geoip_country_code_by_name(3), geoip_country_name_by_name(3). PHP Documentation Group GEOIP_COUNTRY_CODE3_BY_NAME(3)
All times are GMT -4. The time now is 05:49 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy