Summary: | Wrong correction when comparing integers with different numbers of digits in the "Compare numbers" activity | ||
---|---|---|---|
Product: | [Applications] gcompris | Reporter: | lcerf |
Component: | general | Assignee: | Jazeix Johnny <jazeix> |
Status: | RESOLVED FIXED | ||
Severity: | major | ||
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Other | ||
OS: | Linux | ||
Latest Commit: | https://invent.kde.org/education/gcompris/commit/e0b8cbfe9faa6b0d09bac5874df7849eea131f03 | Version Fixed In: | |
Sentry Crash Report: | |||
Attachments: | Second comparison is actually incorrect and the fourth one is actually correct |
Description
lcerf
2023-01-19 15:44:40 UTC
I can reproduce, thank you for the report, I'll make a fix Git commit d7c01f742e1ad318b55ce8c0abe8c495bdcc9b0f by Johnny Jazeix. Committed on 19/01/2023 at 17:11. Pushed by jjazeix into branch 'KDE/3.0'. comparator, fix comparison computation. Previous code was done using strings and 2 was bigger than 11 because of string comparison... M +11 -2 src/activities/comparator/comparator.js https://invent.kde.org/education/gcompris/commit/d7c01f742e1ad318b55ce8c0abe8c495bdcc9b0f Git commit e0b8cbfe9faa6b0d09bac5874df7849eea131f03 by Johnny Jazeix. Committed on 19/01/2023 at 17:12. Pushed by jjazeix into branch 'master'. comparator, fix comparison computation. Previous code was done using strings and 2 was bigger than 11 because of string comparison... M +11 -2 src/activities/comparator/comparator.js https://invent.kde.org/education/gcompris/commit/e0b8cbfe9faa6b0d09bac5874df7849eea131f03 Your reactivity is always impressive. Thank you for the fix. I guess there could be a new activity to compare strings, as in "Would this word be before or after that other word in a dictionary?" (although that would require taking into account the locale!). ;-) (In reply to lcerf from comment #4) > Your reactivity is always impressive. Thank you for the fix. I guess there > could be a new activity to compare strings, as in "Would this word be before > or after that other word in a dictionary?" (although that would require > taking into account the locale!). ;-) We have activities to order letters, words in a sentence, numbers but not words themselves! It would "just" be creating new datasets. The translators take care about the locale, as it is when we translate the strings that we ask the strings to be in the correct order. |