CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

Search:

Type: Posts; User: Judas1012

Page 1 of 6 1 2 3 4

Search: Search took 0.09 seconds.

  1. Re: Read and calc from .txt and print out to another .txt

    FILE * infile;
    infile = fopen ("cels.txt","r");
    if (infile!=NULL)
    {
    fputs ("fopen example",infile);
    fclose (infile);
    }


    Did you just "grab" this sample fopen code from somewhere and...
  2. Re: Algorithm - How to allocate items in a given spaces evenly?

    What is "evenly"? Why not insert the items in the first two spaces? Can you explain with a little more detail?
  3. Thread: C question

    by Judas1012
    Replies
    3
    Views
    412

    Re: C question

    Look at the code: that's exactly what you're telling it to do most of the time.

    Specifically, if motor == 0 coming in to that function, then the first thing that gets evaluated is "is motor == 0?"...
  4. Re: pleeeease help! simple program with a panel class and actionlistener

    Hmm... I don't know why it's giving you that error, but Integer.parseInt returns type "static int", not type "IntegerCalculator" as you have in your code:
    ...
  5. Replies
    1
    Views
    652

    Re: Help with a method in a program

    It looks good to me... how are you calling this function? Can you post the bit of code where you actually call this?

    Also, in Java, don't you have to enclose all conditionals with curly-braces...
  6. Replies
    5
    Views
    1,828

    Re: Simple Program won't work.

    Just making sure! You didn't specify that step in your last post... hehe... wouldn't it have been nice if that were the problem? ;)

    Anyway... I'm thinking it may have something to do with your...
  7. Replies
    4
    Views
    2,434

    Re: A Newbie that Needs Help!

    If this may clarify things a little more:

    Think of a class as a blueprint. That's the perfect thing to think of it as, like GuOddian said.

    You don't have any objects until you create an object...
  8. Replies
    5
    Views
    1,828

    Re: Simple Program won't work.

    Are you compiling the program before you try and run it?

    > javac MyProgram.java
    > java MyProgram
  9. Replies
    2
    Views
    2,699

    Re: Finding Angle of Rotation

    We ran into a problem similar to this and ended up using a "quadrant" test for both X and Y: which quadrant the rotated point would lie in, then we adjusted "New X" and "New Y" by negating the sign...
  10. Replies
    3
    Views
    814

    Re: Help needed in java- i am beginner

    Can you post the code you've written so far?

    We usually don't write code for people, but will gladly help with code you've already written. If you've got a specific question about the execution,...
  11. Thread: lint

    by Judas1012
    Replies
    2
    Views
    391

    Re: lint

    Splint is a re-write of the original lint UNIX application, and should be the same in most respects.
  12. Re: shotest path between two vertices in a graph

    You need the help of Djikstra's algorithm:

    http://en.wikipedia.org/wiki/Dijkstra's_algorithm
  13. Replies
    2
    Views
    6,012

    Re: Address Text Parsing algorithm (mapping)

    What do you want to do? Split the address into "number" and "street", like 504 American St. would be "504" and "American St." and store those in variables or something?

    I don't quite understand...
  14. Replies
    9
    Views
    7,941

    Re: Determining polygon adjacency

    Just a follow-up to our final algorithm.

    We found major problems using the slope of the line to see if two lines were parallel -- first was considering infinite slopes, and the next took a bit of...
  15. Replies
    9
    Views
    7,941

    Re: Determining polygon adjacency

    In the United States, there are approximately 212,000 different blockgroups, each with between 4 and 500 edges (depending on the complexity/population of the blockgroup).

    The slowdown, I...
  16. Replies
    9
    Views
    7,941

    Re: Determining polygon adjacency

    Wow -- that worked absolutely great with a few tweaks. With a little pre-processing (computing all slopes of all edges of all polygons of blockgroups in the US took a little over 15 minutes), now we...
  17. Replies
    9
    Views
    7,941

    Re: Determining polygon adjacency

    Yep, I took care of the vertical line problem by assigning a "hival" value to any slope that is 0... so, the slope of a vertical line is 2,000,000,000 -- an improbable slope. I know this isn't the...
  18. Replies
    9
    Views
    7,941

    Determining polygon adjacency

    Good day, gurus... I'd like to pick some brains for a moment and see if anyone has a better algorithm than the one I've come up with.

    In a nutshell, I'm trying to determine whether two polygons...
  19. Re: Client-Server program and file transfer with sockets

    Yep, using TCP/IP, and I finally figured it out... I was writing 2 more bytes than I needed to due to some crappy math in the program... easy fix, tough hunting it down, though... strange that it...
  20. Client-Server program and file transfer with sockets

    I've got a little client-server program written and am having trouble copying files from the server to the client. It appears that the server writes the correct amount of bytes, and the client reads...
  21. Replies
    0
    Views
    602

    Problems with Client-Server program

    Warning: this is academic in nature... ;)

    I'm trying to write a simple client-server program using named pipes (FIFOs) to compare files and what-not. It seems that the code executes perfectly for...
  22. Re: problem displaying patterns correctly using for loops

    For c, think about how many spaces are at the beginning of the line... and what your current iterative position in the loop is... for example, iteration 0 (the first one) has 0 spaces at the front. ...
  23. Re: Binary Tree Heap - finding the last parent node

    Well, it's not in the fixHeap method -- almost 100% positive it's with the findLastParent() method.
  24. Binary Tree Heap - finding the last parent node

    Got a little trouble writing this one last function for an academic assignment. We're implementing a binary tree max heap with binary tree nodes (not an array, as would be a lot easier!) and am...
  25. Replies
    3
    Views
    473

    Re: Import Anomaly

    It would be helpful if you put only your code inside the code tags and your actual question/query as normal text.
Results 1 to 25 of 132
Page 1 of 6 1 2 3 4





Click Here to Expand Forum to Full Width

Featured