CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
Search Posts SEARCH
Who's Online WHO'S
Log in LOG

Home: Perl Programming Help: Beginner: Re: [iammgg] Two user inputs (String and Integer): Edit Log


May 30, 2017, 4:02 AM

Views: 2116
Re: [iammgg] Two user inputs (String and Integer)

This appears to be a homework assignment so I will not give you the answer, but I will try to help.

This assignment cannot be done without using one or more of Perl's string manipulation functions (index, length,split, substr).

Hint: A loop will not help you. The only test required is the one for "too big". If it is not too big, the number is the index of the letter.

If you are studying arrays, you probably want to split the string into an array of characters. If you are studying strings, use the functions with no array at all.

UPDATE: Added link for length.
Good Luck,

(This post was edited by BillKSmith on May 30, 2017, 8:29 AM)

Edit Log:
Post edited by BillKSmith (Veteran) on May 30, 2017, 8:29 AM

Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives