Skip to main content

Thread: python loop question


so here have function in c removes every instance of specific character in string:

code:
void squeeze(char s1[], char c) {     int i, j;      (i = j = 0; s1[i] != '\0'; i++)         if (s1[i] != c)             s1[j++] = s1[i];     s1[j] = '\0'; }
how in python2? c loops , i'm not sure how go doing same in python2. appreciated!

string.translate(none, char)


Forum The Ubuntu Forum Community Ubuntu Specialised Support Development & Programming Programming Talk [SOLVED] python loop question


Ubuntu

Comments

Popular posts from this blog

Joomla 3.3 Installation Error message - Joomla! Forum - community, help and support

Multilanguage infinite redirect loop error. - Joomla! Forum - community, help and support

Thread: Wine can't find the cd