# Ukrainian pluralization bug

**URL:** https://meta.discourse.org/t/ukrainian-pluralization-bug/54951
**Category:** Translations
**Created:** [December 29, 2016, 9:33pm UTC](https://meta.discourse.org/t/ukrainian-pluralization-bug/54951 "2016-12-29T21:33:30Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![neil](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/neil/32/102150_2.png) [@neil](https://meta.discourse.org/u/neil)
#### Post date: [December 29, 2016, 9:33pm UTC](https://meta.discourse.org/t/ukrainian-pluralization-bug/54951/1 "2016-12-29T21:33:30Z")

</div>

If anyone can help me with pluralization rules in Ukrainian, that would be nice. 😉

Currently, we have [these rules](https://github.com/discourse/discourse/blob/master/app/assets/javascripts/locales/uk.js.erb):

```plaintext
I18n.pluralizationRules['uk'] = function (n) {
  if (n == 0) return ["zero", "none", "other"];
  if (n % 10 == 1 && n % 100 != 11) return "one";
  if (n % 10 >= 2 && n % 10 <= 4 && (n % 100 < 10 || n % 100 >= 20)) return "few";
  return "many";
};

```

If n is 5, then it will default to **many** , but translations we get from Transifex never have **many** in them. e.g.,

```plaintext
    replies:
      one: "1 відповідь"
      few: "%{count} відповідей"
      other: "%{count} відповідей"

```

Should the rules be returning **other** instead of **many**? Or is there a problem with Transifex not returning the translations for **many**?

---

<div class="post-metadata">

### Author: ![gerhard](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/gerhard/32/119479_2.png) [@gerhard](https://meta.discourse.org/u/gerhard)
#### Post date: [December 29, 2016, 11:30pm UTC](https://meta.discourse.org/t/ukrainian-pluralization-bug/54951/2 "2016-12-29T23:30:46Z")

</div>

According to [Unicode](http://www.unicode.org/cldr/charts/29/supplemental/language_plural_rules.html#uk) it should be `one`, `few`, `many` and `other`, where, if I read this correctly, `other` is only used for certain decimal numbers.

So, yeah, this could be a problem with Transifex where they switched `many` and `other`. But I don’t speak Ukrainian, so I may be mistaken.

BTW: Don’t forget the pluralization rules used by [Ruby](https://github.com/discourse/discourse/blob/master/config/locales/plurals.rb#L106-L106) and [MessageFormat](https://github.com/discourse/discourse/blob/master/lib/javascripts/locale/uk.js).

---

<div class="post-metadata">

### Author: ![neil](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/neil/32/102150_2.png) [@neil](https://meta.discourse.org/u/neil)
#### Post date: [December 30, 2016, 3:25pm UTC](https://meta.discourse.org/t/ukrainian-pluralization-bug/54951/3 "2016-12-30T15:25:07Z")

</div>

> [@gerhard](#):
>
> BTW: Don’t forget the pluralization rules used by Ruby and MessageFormat.

Yeah they all include **many** as an option.

 ![](https://global.discourse-cdn.com/meta/original/3X/7/5/752fbc87e0e711c4859bc70fa8c72d0ba63c81d0.png)

Transifex doesn’t have many as an option for translators. Looks like a Transifex bug.
