计算电子邮件地址的打字速度

发布于 2024-12-28 16:07:55 字数 532 浏览 1 评论 0原文

我需要计算用户的打字速度,打字速度是通过输入他的电子邮件地址来计算的。

该用户将与输入其电子邮件地址的其他用户竞争。我的做法是花时间输入他们的电子邮件地址。例如 5 秒

然后获取输入的字符数 例如 23 个字符除以 5(平均字长)

总时间 / 键入的总字数 * 60 = 每分钟字数

问题在于,如果用户的电子邮件很短,则存在差异地址例如 [电子邮件受保护] 他每分钟会收到 170 个单词,而如果您有像 [电子邮件受保护] 每分钟您将收到 55 个单词。

如何找到标准化或增加权重的方法,以便比较打字速度?

I need to calculate the typing speed of the user, the typing speed is calculated by inputting his email address.

The user will compete with other users who typed their email address. How I am doing it is I am getting the time taken to input their email address. e.g. 5 seconds

Then get the number of characters inputted e.g. 23 characters divide that by 5 (average word length)

Total Time / Total Words typed * 60 = Words per minute

The problem is that there is a discrepancy, if a user has a short email address e.g. [email protected] he will get 170 words per minute whilst if you have an average one like [email protected] you will get 55 words per minute.

How can I find a way to standardize or add weight so that I can compare typing speed?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

无人问我粥可暖 2025-01-04 16:07:55

您可以通过让用户键入相同的输入来实现标准化。当您让他们输入非常少量的数据时,这一点尤其重要。考虑以下几点:

Lorem ipsum dolor sat amet,consectetur adipiscing elit。 Nulla Feris nec quam accumsan venenatis porta ligula vehicula。 Praesent vitae sapien vitae velit tempor luctus eget a enim。 Praesent eros metus,commodod id adipiscing vitae,congue eu Tellus。 Nullam feugiat,马萨在 adipiscing congue,tellus dui mollis nibh,id convallis metus libero sed libero。 Pellentesque 居民 morbi tristique senectus et netus etmalesuada 名声 ac turpis egestas。 Nunc vitae congue eros。 Sed非Fringilla purus。 Quisque lectus leo、lacinia vitae elementum at、laoreet eget leo。整数坐 amet orci Tellus。 Sed diam metus,elementum id varius at,iaculis sat amet eros。

我每分钟大约需要 28 个单词(这比我正常的打字速度慢得多)。这是大量文本,但更重要的是它不是通常键入的文本。这不是我的母语,所以我必须慢慢分析每个单词。它不是由我经常输入的内容组成的。等等。

每分钟大约需要 600 个单词(尽管很难估计,因此存在很大的误差范围)。至少可以说是个人最好的。

为什么这些结果差异如此之大?因为我正在输入非常不同的东西。当你在这个方程中添加另一个变量(多人)时,你会得到更多的变化。

您需要标准化测试。当教育机构测试学生时,他们通常会让这些学生执行相同的任务,即使不是至少功能相同的任务。这有助于消除变量,以便唯一的变量就是被测试的人……人。

You standardize by having the users type the same input. This is especially important when you're having them enter very small amounts of data. Consider the following:

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla fermentum felis nec quam accumsan venenatis porta ligula vehicula. Praesent vitae sapien vitae velit tempor luctus eget a enim. Praesent eros metus, commodo id adipiscing vitae, congue eu tellus. Nullam feugiat, massa at adipiscing congue, tellus dui mollis nibh, id convallis metus libero sed libero. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Nunc vitae congue eros. Sed non fringilla purus. Quisque lectus leo, lacinia vitae elementum at, laoreet eget leo. Integer sit amet orci tellus. Sed diam metus, elementum id varius at, iaculis sit amet eros.

This took me approximately 28 words per minute (which is much slower than my normal typing speed). It's a significant amount of text, but even more importantly is the fact that it's not normally typed text. It's not in my native language, so I had to slowly analyze each word. It's not composed of things I type very often. And so on.

I

This took me approximately 600 words per minute (though it was difficult to estimate, so there's a significant margin of error there). A personal best to say the least.

Why did these results vary so significantly? Because I was typing very different things. When you add another variable to this equation (multiple people), you get even more variation.

You need to standardize the test. When educational institutions test their students, they generally have those students perform identical, if not at least functionally equivalent, tasks. This helps eliminate variables so that the only variable is the one being tested... the person.

命比纸薄 2025-01-04 16:07:55

尝试按照以下方式进行操作:

    <!doctype html>
<html>
    <body>
        <textarea id="email_add"></textarea>
        <input type="button" value="Done" id="done"/>

        <script>
            var doneButton = document.getElementById('done');
            var emailArea = document.getElementById('email_add');
            var lengthOfEmail = 0;
            var time_start = 0;
            var time_end = 0;



            emailArea.onkeyup = function() {
                lengthOfEmail++;
                if(lengthOfEmail == 1) time_start = new Date();
                else time_end = new Date().getTime() - time_start;
            }

            doneButton.onclick = function() {
                alert("Email Length: " + lengthOfEmail);
                alert("Time: " + time_end + " milliseconds.");
            }
        </script>
    </body>
</html>

现在,您需要调整电子邮件地址长度以适应输入“@”符号时按下的转变。但这应该可以帮助您获得时间,并提供一种方法来验证它们不仅仅是复制和粘贴。

Try something along these lines:

    <!doctype html>
<html>
    <body>
        <textarea id="email_add"></textarea>
        <input type="button" value="Done" id="done"/>

        <script>
            var doneButton = document.getElementById('done');
            var emailArea = document.getElementById('email_add');
            var lengthOfEmail = 0;
            var time_start = 0;
            var time_end = 0;



            emailArea.onkeyup = function() {
                lengthOfEmail++;
                if(lengthOfEmail == 1) time_start = new Date();
                else time_end = new Date().getTime() - time_start;
            }

            doneButton.onclick = function() {
                alert("Email Length: " + lengthOfEmail);
                alert("Time: " + time_end + " milliseconds.");
            }
        </script>
    </body>
</html>

Now, you're going to want to adjust the email address length to accommodate for the shift that's pressed when the '@' symbol is entered. But this should help you get the time, along with a way of verifying that they're not just copying and pasting.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文