Thread: need some C programs immediately

  1. #1
    Registered User
    Join Date
    Feb 2013
    Posts
    10

    need some C programs immediately

    Be given a string of chars, where each single char belongs to the following alphabet: a..zA..Z0..9 (So, in the string there are only lowercases, uppercases and digits. No blank, no comma, ...).
    For every char of the given alphabet, count how many times in the string
    1----- the char is preceded by its predecessor in the alphabet (consider that the predecessor of 'a' is '9')

    2---- the char is followed by its successor in the alphabet (consider that the successor of '9' is 'a')

    3---the char belong to a sequence of identical chars whose length is at least three (i.e.: in the string cc74uyrpfccc348fhsjcccc3848djccccc484jd for three times the character 'c' satisfies this condition)

    4----- what is the longest substring of characters strictly rising (the following is greater (>) of the previous)
    5.... what is the longest substring of successive characters (i.e.: fhkjshdfruytyzABCDEfglsj => 7)

    6------ the frequencies of any char (if in the string the character 'g' occurs 12 times, its frequency is 12)

  2. #2
    Registered User
    Join Date
    May 2009
    Posts
    4,183
    Read this link Announcements - General Programming Boards

    Show some effort!
    Ask a meaningful question.

    Tim S.
    "...a computer is a stupid machine with the ability to do incredibly smart things, while computer programmers are smart people with the ability to do incredibly stupid things. They are,in short, a perfect match.." Bill Bryson

  3. #3
    Registered User
    Join Date
    Mar 2011
    Posts
    546
    "need some C programs immediately"

    I need some of those too.

  4. #4
    Registered User
    Join Date
    Nov 2010
    Location
    Long Beach, CA
    Posts
    5,909
    I need two hookers and a kilo of blow. Bet I'll get mine before you get yours .

  5. #5
    Registered User
    Join Date
    Jun 2011
    Posts
    4,513
    Party at anduril462's! I'll bring a keg of homebrew.

  6. #6
    Registered User
    Join Date
    Nov 2010
    Location
    Long Beach, CA
    Posts
    5,909
    Quote Originally Posted by Matticus View Post
    Party at anduril462's! I'll bring a keg of homebrew.
    Sweet, my brew could use some company. I have an unused tap on my kegarator.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. start with c++ immediately?
    By DennChooch in forum C++ Programming
    Replies: 9
    Last Post: 09-26-2012, 09:45 AM
  2. Replies: 17
    Last Post: 11-24-2010, 06:59 PM
  3. I Need An immediately Help plz
    By SONY in forum C++ Programming
    Replies: 7
    Last Post: 10-17-2007, 10:34 PM
  4. Need Help Immediately
    By McGOOF in forum C Programming
    Replies: 2
    Last Post: 11-23-2004, 12:27 PM
  5. help needed immediately
    By noob2c in forum C Programming
    Replies: 1
    Last Post: 04-11-2003, 04:57 PM