#!/usr/local/bin/perl -i # this program replaces ise by ize in a file, overwriting the original file. # the final ten lines show the exceptions to this rule $to = 0 ; $from = 0 ; $undo = 0 ; $other = 0 ; while( <>){ $to += s/ptimis/ptimiz/g; $undo += s/optimiztic/optimistic/g; $to += s/egularis/egulariz/g; $to += s/inimis/inimiz/g; $to += s/aximis/aximiz/g; $to += s/meteris/meteriz/g; $to += s/recognis/recogniz/g; $to += s/penalis/penaliz/g; $to += s/utilis/utiliz/g; $to += s/recognis/recogniz/g; $to += s/apologis/apologiz/g; $to += s/racteris/racteriz/g; $undo += s/racterizt/racterist/g; $to += s/phasise/phasize/g; $to += s/fantasise/fantasize/g; $to += s/localis/localiz/g; $to += s/ormalis/ormaliz/g; $to += s/neralis/neraliz/g; $to += s/summaris/summariz/g; $to += s/ginalis/ginaliz/g; $to += s/inearis/ineariz/g; $to += s/formalise/formalize/g; $to += s/riticise/riticize/g; $to += s/cretise/cretize/g; $to += s/visualise/visualize/g; $to += s/tialis/tializ/g; $to += s/pardise/pardize/g; $to += s/emoris/emoriz/g; $to += s/domise/domize/g; $to += s/ymmetrise/ymmetrize/g; # while we are at it: $other += s/predicitve/predictive/g; $other += s/predicitive/predictive/g; $other += s/probabililty/probability/g; $other += s/probalities/probabilities/g; $other += s/properites/properties/g; $other += s/propostion/proposition/g; $other += s/qudratic/quadratic/g; $other += s/labelled/labeled/g; $other += s/reponse/response/g; $other += s/repsect/respect/g; $other += s/respewct/respect/g; $other += s/zeroeth/zeroth/g; $other += s/usally/usually/g; $other += s/transtition/transition/g; $other += s/tranform/transform/g; $other += s/sysstems/systems/g; $other += s/satisifes/satisfies/g; $other += s/sigificance/significance/g; $other += s/solveable/solvable/g; $other += s/substracted/subtracted/g; $other += s/succesf/successf/g; $other += s/logisitic/logistic/g; $other += s/minimse/minimize/g; $other += s/mutliscale/multiscale/g; $other += s/neurtrino/neutrino/g; $other += s/occurence/occurrence/g; $other += s/occuring/occurring/g; $other += s/maximially/maximally/g; $other += s/assym/asym/g; $other += s/assyn/asyn/g; $other += s/commital/committal/g; $other += s/continous/continuous/g; $other += s/limitting/limiting/g; $other += s/disciminative/discriminative/g; $other += s/equalling/equaling/g; $other += s/familar/familiar/g; $from += s/riticizm/riticism/g; # and just to check that the rules are obeyed: $from += s/chastize/chastise/g; $from += s/circumcize/circumcise/g; $from += s/compromize/compromise/g; $from += s/disfranchize/disfranchise/g; $from += s/improvize/improvise/g; $from += s/supervize/supervise/g; $from += s/surmize/surmise/g; $from += s/televize/televise/g; print ; } print STDERR "Changed iz -> is $to - $undo times, and is -> iz $from times, and corrected $other other spellings\n" ;