How to insert random characters in a text file at random positions using C

Posted by Shantanu Gupta on Stack Overflow See other posts from Stack Overflow or by Shantanu Gupta
Published on 2010-03-20T17:45:03Z Indexed on 2010/03/20 17:51 UTC
Read the original article Hit count: 429

Filed under:
|

I m writing a program to insert random characters in a text file in between the text so that no one can understand this text.

eg.

suppose this is my text file a.txt with content as

"Hi my name is abc. I like to play XYZ"

Now i will cal a random function in C and get the 26 modulus random no to get the character to be inserted at random position.

eg.

"Him mayn mae lkd". etc

How can i insert this random character in between the file.

© Stack Overflow or respective owner

Related posts about c

    Related posts about c++