Service "One second code" which can check the program how many times the computer can execute in 1 second by quiz format



It is very difficult to intuitively understand how fast the computer will run the program. So, in order to understand the speed of the computer, we can learn how many loops of a simple program can be looped per second by answering quizzes "One second code"Has been created by the programmer.

One second code: Do YOU ​​how many your computer can do in a second?
http://computers-are-fast.github.io/

This is the first quiz. If you answer in quiz format how the program "sum.c" below loops how many programs in 1 second. A program written in C language is a simple thing "to count input figures in 1 increments".


A quiz is a mechanism that answers within a range, and if it is within 10 times (1/10 times) the error, it is a style called correct answer. For example, if you think that "50 (times)" is the correct answer, selecting "10" or "100" as a number from 10 to 100 will be the correct answer. For this time, please click "1,000,000,000" on anticipation that you can execute huge number of "hundreds of millions of levels".


Then the number indicating the range of the correct answer turns green and a check mark which is the correct mark is displayed. The answer seems to be "550 million times".


Following C languagePythonA simple loop program written in.


While thinking that "It is probably much later than C language", please click "1,000,000".


In case of incorrect answer, the number you clicked turns red and an "x" mark is displayed. The correct answer is 68 million times. In this way, it is OK to answer the number of loops possible in quiz format for all 18 questions written in C language and Python.


1秒間に繰り返されるプログラムの数は、コンピュータの速度だけで決まるわけではありません。例えば、以下の問題は、http://google.comから応答が何回あるかを考えるクイズ。


The correct answer is 4 times. In this case it seems that response speed from Google server is a bottleneck.


In programs that think about the number of times of writing, there are conditions such as "When writing to SSD", so we need to consider it accordingly.


Since it is necessary to estimate the execution speed of the program taking into consideration various conditions such as memory and CPU cache memory speed need to be assumed, it is possible to image not only the programming knowledge but also the actual behavior somehow It seems that things like "skin sensation" are also tried.


The correct answer number and the remaining problem number are displayed at the bottom of the browser. The result is "5/18" and sinking.


In One second code, the program language issued in quizzes is limited to C language and Python, but those who are confident in comprehensive knowledge of computer languages ​​such as computer languages, hardware, and networks answer to all 18 questions It seems good to compete the score.

in Web Service, Posted by darkhorse_log