Announcement

Collapse
No announcement yet.

Finally Got This Code Working

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Finally Got This Code Working

    Okay, I know this won't make much sense or matter to most of you, but I'm bouncing off the walls here and had to share it somewhere, so here it is.

    I've been working on a small snippet of code for about two weeks now. Total length? Less than 50 lines. And I've been hammering at it every night for the past two weeks, trying to get it to make a menu automatically.

    Every night, I come up with a couple more ways to try it out, and every night, the computer laughs at me. I've been struggling, and very hard, with this, until about 10 minutes ago.

    I finally made it work. It does exactly what I wanted it to do, exactly how I wanted it to do it. And everybody who I know who I've spoken to about this is asleep (it's 1:15am here). So no sharing success until tomorrow sometime, dammit.

    Bouncing off the walls and happy about it. God, it feels good when something works after that much effort, especially when I was considering just flat out giving up earlier tonight.

    yay!

  • #2
    *happy dances in your honor*
    It always feels wonderful when things like this happen.
    1129. I will refrain from casting Dimension Jump and Magnificent Mansion on every police box we pass.
    -----
    http://orchidcolors.livejournal.com (A blog about everything and nothing)

    Comment


    • #3
      Great feeling when it all suddenly comes together isn't it

      Arp happens!

      Just when I was getting used to yesterday, along came today.

      Comment


      • #4
        I had that feeling before, too.

        Had a math problem that I could NOT get done, for hours on end, was staring at the dang book forever. Went to bed, relaxed a little bit, and POOF the answer showed up in my head.

        Was great!

        Good going, Buddy!!!

        Cutenoob
        In my heart, in my soul, I'm a woman for rock & roll.
        She's as fast as slugs on barbituates.

        Comment


        • #5
          I know your pain, but with the joy of triumph.

          Back in college, my best friend and I were partners on a coding project for a COBOL class. (An aside: I dislike detest loathe really, really, really, really hate COBOL. With the intense fiery passion of a thousand suns.)

          Anyway, the project was 25% of our grade and due at the end of the term. We slaved over the bloody thing, making all the pieces work. We finally get to testing and it runs the first 4 lines of test data properly. Then spews garbage.

          Okay, skim through the code, make a couple changes. Now it runs the first 6 lines of data properly, then garbage. For jollies, I run it again, we get only 3 good lines of output, then garbage yet again.

          We print out the code, go line by line, character by character, referencing all of our notes and the textbook. It looks fine, and since it is a loop that reads the data from the file and feeds it as output, if it works on the first line then it should work on every line.

          We try a fresh copy of the data file, thinking maybe it was corrupt, but still a no go. We worked for an entire week on the final version and couldn't find the problem, ending up with having to turn it in spewing garbage after X number of lines, where X is an integer between 1 and 9.

          So, the teacher called us in for a meeting, explained that we were getting an F on the project because the program didn't work. Bringing our B's down to D's. :sad:

          We explained the issues we were having, explained all of the troubleshooting and review, and asked her if she could help us find the mistake so we would at least know what we screwed up.

          She spent 8 hours combing through the code with us. She said our code was perfect as far as she could tell, and there was no reason it shouldn't work. Sadly, the grade was based on the software working, not her review of the code.

          To this day, I still don't know why the hell it wouldn't work.

          Sorry for the threadjack. Congrats on getting yours working!

          Comment


          • #6
            Quoth Cutenoob View Post
            Went to bed, relaxed a little bit, and POOF the answer showed up in my head.
            I even did did that, and the dreamed up solution still failed. This was easily one of the hardest things I've ever done, even though I've done similar stuff many times before. It was weird to be so frustrated by something so simple.

            Quoth Gerrinson View Post
            To this day, I still don't know why the hell it wouldn't work.

            Sorry for the threadjack. Congrats on getting yours working!
            I had that happen to me in college a few times, but with Pascal instead of Cobol. I had checked through everything multiple times, and could not get it to work. Finally, an idea had come up that only can come from desperation: I printed the source code and retyped it.

            Ready for the weird part? It worked. I never could spot any differences between the printout and what was on-screen. Retyping it worked, though.

            Since then, I've learned about the non-printing characters. I'll bet you had one somewhere, and the compiler produced a bogus executable, but never told you. End result was erratic output for no visible reason. And nothing short of a machine code viewer / hex editor could possibly reveal it.

            Comment

            Working...
            X