Reading Time Estimator
估计阅读文本所需的时间。
0
单词
0
字符
0
句子
0
段落
阅读时间
—
@ 238 WPM
朗读时间
—
@ 130 WPM
关于此工具
阅读时间估算器是一个实用工具,根据平均阅读速度计算阅读一段文本需要多长时间。无论你是核实文章长度的作家、规划学习时间的学生,还是管理受众参与度的内容创作者,了解预估阅读时长都有助于你判断内容的复杂程度和读者的投入时间。这个工具通过提供即时的数据驱动估算,消除了内容规划中的猜测。
只需将文本粘贴或输入到输入框中,工具就会根据标准阅读速度指标自动计算阅读时间。该估算基于典型的单词阅读速率(通常成人为每分钟200至250个单词),并以分钟和秒为单位显示结果。使用它来优化博客文章、社交媒体内容、文档或任何其他需要传达读者时间投入的书面材料。
常见问题
代码实现
def estimate_reading_time(text: str, wpm: int = 238) -> dict:
"""
Estimate reading time for a given text.
Default WPM is 238 (average adult silent reading speed).
"""
words = text.split()
word_count = len(words)
minutes = word_count / wpm
seconds = round(minutes * 60)
return {
"word_count": word_count,
"char_count": len(text),
"char_no_spaces": len(text.replace(" ", "")),
"minutes": round(minutes, 1),
"seconds": seconds,
"display": format_time(seconds),
}
def format_time(total_seconds: int) -> str:
if total_seconds < 60:
return f"{total_seconds} sec read"
minutes = total_seconds // 60
seconds = total_seconds % 60
if seconds == 0:
return f"{minutes} min read"
return f"{minutes} min {seconds} sec read"
# Example
text = """
Reading time estimators divide word count by average reading speed.
The average adult reads about 200-250 words per minute silently.
Technical content is typically slower at 100-150 WPM.
"""
result = estimate_reading_time(text)
print(f"Words: {result['word_count']}")
print(f"Time: {result['display']}")Comments & Feedback
Comments are powered by Giscus. Sign in with GitHub to leave a comment.