Results 1 to 6 of 6

Thread: Ugh, finally got the isValid function done

  1. #1
    Reemer's Avatar
    Joined
    Dec 2011
    Posts
    639
    Userbars
    8
    Thanks
    364
    Thanked
    446/256
    DL/UL
    39/0
    Mentioned
    203 times
    Time Online
    4d 13h 47m
    Avg. Time Online
    1m

    Ugh, finally got the isValid function done

    Would've been a lot easier to count the number of *'s and |'s if I didn't reset their count to 0 every time the loop ran.
    Anyone else hate making stupid mistakes like that? It seems to happen to me a lot.

  2. #2
    Saiyan Race
    j03's Avatar
    Joined
    Dec 2011
    Posts
    13,735
    Userbars
    175
    Thanks
    5,920
    Thanked
    33,142/6,614
    DL/UL
    23/36
    Mentioned
    3,871 times
    Time Online
    563d 23h 55m
    Avg. Time Online
    3h 13m
    Haha yeah..............sort of...
    (you need an account to see links)
    (you need an account to see links)(you need an account to see links)

    ------------------------
    [02/24/2013] Stealth CORE is made into the first standalone Neopets auto-player.
    ------------------------


  3. #3

    Joined
    Dec 2011
    Posts
    488
    Thanks
    303
    Thanked
    559/263
    DL/UL
    13/4
    Mentioned
    34 times
    Time Online
    1h 58m
    Avg. Time Online
    N/A

  4. #4
    Zachafer's Avatar
    Joined
    Dec 2011
    Posts
    1,235
    Userbars
    11
    Thanks
    769
    Thanked
    1,466/678
    DL/UL
    98/0
    Mentioned
    512 times
    Time Online
    24d 13h 9m
    Avg. Time Online
    8m
    What were you trying to do? I think I know a real easy way to do it.

  5. #5
    Reemer's Avatar
    Joined
    Dec 2011
    Posts
    639
    Userbars
    8
    Thanks
    364
    Thanked
    446/256
    DL/UL
    39/0
    Mentioned
    203 times
    Time Online
    4d 13h 47m
    Avg. Time Online
    1m
    Quote Originally Posted by Zachafer View Post
    What were you trying to do? I think I know a real easy way to do it.
    It was just for a Java assignment, it had to do with the Mayan number system, which was base 20. It only had four characters that were valid: "*", "|", "0", " ". The *'s were 1 and |'s were 5. |** would be 7 and * | would be 25 (because of the space). It had to be in a certain order (**| wouldn't work), and only 3 |'s were allowed and 4 *'s. No other characters were allowed either.

    It wasn't so bad once I realized my silly mistake. Got the assignment done pretty easily after that.

  6. #6
    Zachafer's Avatar
    Joined
    Dec 2011
    Posts
    1,235
    Userbars
    11
    Thanks
    769
    Thanked
    1,466/678
    DL/UL
    98/0
    Mentioned
    512 times
    Time Online
    24d 13h 9m
    Avg. Time Online
    8m
    Next time check out regex!

  7. The Following User Says Thank You to Zachafer For This Useful Post:

    Miguel (03-11-2012)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •