From ed1d0fd7143c583ffa9f204a0b51b77309b71dd1 Mon Sep 17 00:00:00 2001 From: Lan Hui <1348141770@qq.com> Date: Fri, 11 Aug 2023 21:02:22 +0800 Subject: [PATCH] Show only one place after the decimal point. --- app/Article.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Article.py b/app/Article.py index 467224a..acc8aa5 100644 --- a/app/Article.py +++ b/app/Article.py @@ -93,8 +93,8 @@ def get_today_article(user_word_list, visited_articles): today_article = None if d: today_article = { - "user_level": '%4.2f' % user_level, - "text_level": '%4.2f' % text_level, + "user_level": '%4.1f' % user_level, + "text_level": '%4.1f' % text_level, "date": d['date'], "article_title": get_article_title(d['text']), "article_body": get_article_body(d['text']),