Jump to content

stewarty77

Members
  • Posts

    6
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

stewarty77's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. [!--quoteo(post=358059:date=Mar 24 2006, 10:23 PM:name=kenrbnsn)--][div class=\'quotetop\']QUOTE(kenrbnsn @ Mar 24 2006, 10:23 PM) [snapback]358059[/snapback][/div][div class=\'quotemain\'][!--quotec--] I have been trying to post a similar solution for the past 2 hours but keep getting a "406 error -- Not Acceptible" error. :-( Ken (since this post worked, let's see if editing the post to add code will work) (nope :-( ) [/quote] Thanks your help with this matter is greatly appreciated!
  2. [!--quoteo(post=357975:date=Mar 24 2006, 05:12 PM:name=keeB)--][div class=\'quotetop\']QUOTE(keeB @ Mar 24 2006, 05:12 PM) [snapback]357975[/snapback][/div][div class=\'quotemain\'][!--quotec--] Write a function to do it. It wouldn't take long.. [code]function returnPosInAlphabet($char) {     switch ($char) {         case 'a':             return 1;         case 'b':             return 2;     } }[/code] [= [/quote] Ok got the function created function returnPosInAlphabet($char) { switch ($char) { case 'A': return 1; case 'B': return 2; case 'C': return 3; case 'D': return 4; case 'E': return 5; case 'F': return 6; case 'G': return 7; case 'H': return 8; case 'I': return 9; case 'J': return 10; case 'K': return 11; case 'L': return 12; case 'M': return 13; case 'N': return 14; case 'O': return 15; case 'P': return 16; case 'Q': return 17; case 'R': return 18; case 'S': return 19; case 'T': return 20; case 'U': return 21; case 'V': return 22; case 'W': return 23; case 'X': return 24; case 'Y': return 25; case 'Z': return 26; } } I'm using str_split("string entered") to split the string entered but it returns Array, anymore suggestions what to do next, oh and I'm not to good at the programming as you might have guessed!
  3. Hi Say if the user was to input a string "hello". I need php to print the string by letter and give its numerical position in the alphabet: h = 8 e = 5 l = 12 l = 12 o = 15 Any suggestions?
  4. [!--quoteo(post=356457:date=Mar 19 2006, 07:27 PM:name=earl_dc10)--][div class=\'quotetop\']QUOTE(earl_dc10 @ Mar 19 2006, 07:27 PM) [snapback]356457[/snapback][/div][div class=\'quotemain\'][!--quotec--] check any nearby loops (ie, perhaps a loop to fill the array) I normally time out on neverending loops if I forget something, but the actual line that it displays as timing out is sometimes only related to the loop, not actually in it [/quote] Thanks, you were right, I had that line of code within a while loop, once I took it out it worked fine. Your help was much appreciated!
  5. Hi I have an array $byteslist which contains a list of integers gathered from a MySQL database. I am using the following code: $totalbytes = array_sum($byteslist); But I get the following error: Fatal error: Maximum execution time of 30 seconds exceeded Where am I going wrong?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.