My turn to apologise for premature sending of email...

For some reason I didn't notice the section of mail after
the code snippet!

Alan G

"Dan Liang" <danlian...@gmail.com> wrote in message


Now since I have to work on different data format as follows:

-------------Begin data----------------------------
w1    \t   case_def_acc   \t          yes
w2‬    \t   noun_prop   \t               no
‭w3‬    \t   case_def_gen   \t
w4    \t   dem_pron_f   \t             no
-------------End data----------------------------
Notices that some lines have nothing in yes-no filed, and hence end in a
tab.

My question is how to replace data in the filed of composite tags by
sub-tags like those in the dictionary values above and still be able to
print the whole line only with this change (i.e, composite tags replace by
sub-tags).


_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to