Write an interactive c program that will encode or decode a line of text. To encode a line of text, proceed as follows: Convert each character, including blank spaces, to its ASCII equivalent. Generate a positive random integer. Add this integer to the ASCII equivalent of each character. The same random integer will be used for the entire line of text. Suppose that N1 represents the lowest permissible value in the ASCII code, and N2 represents the highest permissible value. If the number obtained in step 2 above exceeds N2, then subtract the largest possible multiple of N2 from this number, and add the remainder to N1. Hence the encoded number will always fall between N1 and N2, and will therefore always represent some ASCII character. Display the characters that correspond to the encoded ASCII values. The procedure is reversed when decoding a line of text. Be certain, however, that the same random number is used in decoding as was used in encoding.
1 13095Post New CSJM C Interview Questions
What are the various regions of operation of mosfet? How are those regions used?
Could you anyone share me the path to download the automation tools which are having trial license version?
What are semaphores in linux?
What is a solution explorer in visual studio?
How do you choose an algorithm for a classification problem?
What does jre stand for?
Have you attended the client meetings?
What is the difference between responsebody and responseentity?
What is difference between activity type and maintenance activity type?
How do I create standard texts for the sapscripts?
How do you define equipment/material loaned/leased to a customer?
WebSphere Application Server stores passwords XOR encoded. I'd like to use something stronger. What can I do?
What are independent graphics subsystems?
What is the full form of dos?
By default, which replica sets are used to write data?