Dear Sir. I am a new beginner in c language, and I have a problem as follow: I have a file (f1.txt) with data for example: 000111111000111000000000111111000??? I want to read this file and save the result in other file, called (f2.txt), the reading procedure is as follow: 1-every three zeros change to one 0. 2-every three ones change to one 1. So the result of the file (f2.txt) should be as: 01101000110? Any help is welcomed. _________________________________________________________________ MSN 8 with e-mail virus protection service: 2 months FREE* http://join.msn.com/?page=features/virus -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads