1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Encrypt text file into ASCII codes. PLEASE HELP!!!

Discussion in 'C' started by AndreeaRO, Feb 17, 2018.

?

ASCII???

  1. Multiple codes

    0 vote(s)
    0.0%
  2. using hex, dec, octal

    0 vote(s)
    0.0%
Multiple votes are allowed.
  1. AndreeaRO

    AndreeaRO New Member

    Joined:
    Feb 14, 2018
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Gender:
    Female
    Hello everyone!! I am very happy to be part of this community. I have a problem and I could really use some help. I have an assignment that I cannot do. I am very new in programming, like 3 months. So please be patient. I must create a menu in #C that requires next:
    two students have created a two steps method to encrypt a message in a text format. First off all they must transform each character from the initial text in ASCII code. Second, they write the codes in different Ascii format(octal, decimal hex. in this specific order, at line level) Example "I am student" = 111 32 61 155 040 115 74 165 100 65 156 116 like you can see , the first char is octal, the second is decimal and the third is hex.
    the menu requires: C- read a multiple lines from text file , ending in "." char the last char: "." must be eliminated
    A- Display the text (coded in Ascii);
    L- Count the lines from the text file;
    V- Display the text(Ascii) putting a comma after every word(code number)
    N- number of words ( ascii codes including spaces) from each line;
    D- Display the message ( decrypting it )
    E- Insert a string and encrypt it;
    I- Information
    T- close program

    Please forgive my english. I really like programming and I want to learn. It is difficult after almost 9 years after high school. I have attached the picture I have with the assignment. It is in romanian but the menu is the one above. I just wanted to show you how it must be done. take in consideration that I must use simple C. No things like System use or high level programming. Imagine that you are just learning. I really need help. I would love to see an example. This is the way I understand better. Thank you
     

    Attached Files:

Share This Page