2

Esperanto have several useful affixes when it comes to describe containers. At least for set/element, it seems to me that -ar-/-er- makes a rather obvious pair.

When it comes to referring something playing a container, we also have -ej-, -uj-, -ing- affixes. Can ĉe- and/or en-, or any affix, be used as obvious counterpart of those?

While they seems rares, you can find ĉe- used as prefix, like in ĉeesti ĉemane, ĉemara, ĉeorta, ĉevoja and ĉetable. But many words are full root beginning with "ĉe", like ĉetio and ĉevalo. There is also the ĉef- prefix. Also ĉeno is a common word in programming languages, which is the applied domain I'm interested about here. Finally, PIV give "Plej malgranda adresebla parto de memorilo" pour ĉel/o.

The usage of en- seems far more prevalent to refer at something contained in, and you can indeed find it in "enhavo" (content) for example.

I'm especially in doubt regarding -ej- and -uj-, which as far as I understand both can mean "the thing known to contain some kind of element". I think that the definition for "ĉelo" allow to draw my doubt about how they should be understood in a programmatic context. It's really a metonymic problem: sure ĉelo is the container, but when you say multiply this cell by this one, you are implicitly stating to multiply (the value of) their respective content.

On the other hand, one might say that, whatever the container type is, -er- is always relevant, so maybe the distinction for dereferencing can be explicetly typed but it's fine.

Still, here are the types of containers I think having distintive pair of affixes for container/element would be interesting in programming language:

  • set (aro)
  • array (that is, one dimension directly addressable set, I would translate as vico)
  • matrix (two dimensions, matrico)
  • table (any integer dimensions, tabelo)
  • associative array (akompana tabelo)
  • list/iterable (listo/iteraceblo)
2

I'm not sure I understand your question correctly, but I would assume the -an- affix is what you want, so an array element would be a vicano.

  • 1
    "vicero" estus komprenebla en tiu kunteksto surbaze de viaj jamaj pripensoj. – mondano Jan 6 '17 at 15:59
  • That's the kind of answer I'm expecting, thank you. To my mind, -an- would make a better fit for specifying an instance of a class in OOP (-aĵ- could also be a good fit for that I think). – psychoslave Jan 6 '17 at 16:00
0

What affix, if any, can be used to reference an element of [an] array?

If this is for Object Orientated Programming, then you can say:

  • objekto = object
  • ajxo = thing
  • ero = element

Mi programas liston da objektoj.

  • Aĵo is a concrete thing, so it might be used as a convention for naming instances of a class, as well as ano as "member of a class". There is also -id- which might be useful regarding derivative classes. – psychoslave Jan 9 '17 at 8:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.