Thread: Decoding

  1. #1
    Registered User
    Join Date
    Oct 2009


    Hi Guys,

    Working on an encoding and decoding example and have the encoding working fine. Its the decoding that is proving to be a challenge...

    Essentially, I am encoding characters like:


    to give output like


    and thats fine, its just when i want to decode something like:

    2t3y2r to ttyyyrr

    is where i have diffculties

    I have tried a few different ways but I'm stumped and would greatly appreciated a few pointers.

    I think its the printf where im going wrong, I cant seem to grasp how to tell the program to print t twice (above example) when 2 is in front of it

  2. #2
    Jack of many languages Dino's Avatar
    Join Date
    Nov 2007
    Katy, Texas
    methinks you forgot to post your code.
    Mac and Windows cross platform programmer. Ruby lover.

    Quote of the Day
    12/20: Mario F.:I never was, am not, and never will be, one to shut up in the face of something I think is fundamentally wrong.

    Amen brother!

  3. #3
    {Jaxom,Imriel,Liam}'s Dad Kennedy's Avatar
    Join Date
    Aug 2006
    Your problem is on line 26, just before the return.

    That'd be POST YOUR CODE!!!!

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Help with decoding program...
    By porsche911nfs in forum C++ Programming
    Replies: 18
    Last Post: 04-10-2009, 12:21 AM
  2. Help decoding base_64+GZipped string
    By Zeokat in forum C# Programming
    Replies: 3
    Last Post: 12-05-2008, 05:06 PM
  3. Decoding applications?
    By Hybird in forum C++ Programming
    Replies: 2
    Last Post: 11-13-2005, 07:19 AM
  4. Decoding
    By jk81 in forum C Programming
    Replies: 4
    Last Post: 11-12-2002, 11:24 PM
  5. Decoding & Encoding the sound?!?
    By waldis in forum C++ Programming
    Replies: 2
    Last Post: 10-20-2002, 06:41 PM