On Tue, 8 Mar 2022 at 04:06, Jen Kris via Python-list <python-list@python.org> wrote: > But with the C API it looks like this: > > PyObject *pSentence = PySequence_GetItem(pSents, sent_count); > PyObject* str_sentence = PyObject_Str(pSentence); // Convert to string > > PyObject* repr_str = PyObject_Repr(str_sentence);
You convert it to a string, then take the representation of that. Is that what you intended? ChrisA -- https://mail.python.org/mailman/listinfo/python-list