Search:

Type: Posts; User: brane_sail

Search: Search took 0.00 seconds.

  1. nevermind. I just saw the last post about the...

    nevermind. I just saw the last post about the double character, but didn't even notice it in the code until now. Now the code runs fine.

    I've recently switched to python, and gotten used to the...
  2. sorry for that. The code is a little messy, but...

    sorry for that. The code is a little messy, but i've attached it below. Also, i've pasted part of the data file that goes along with it. The actually files are much larger, but this is how they would...
  3. dynamic array has junk digits attached to beginning of each element

    I have been experimenting with dynamic arrays, but have run into a problem with the output. Whenever I read in the numbers from a file, they are correct (output them to the screen to check), but once...
  4. Replies
    9
    Views
    1,523

    Okay, so i went back through the code, and after...

    Okay, so i went back through the code, and after tightening it up a bit found that it was easier to avoid using the subroutine to call the recursion from. It works a little better now, but with all...
  5. Replies
    9
    Views
    1,523

    I am going to take one more crack at it before I...

    I am going to take one more crack at it before I go so far as to post the whole thing, as it is pretty complex and not very well commented :(

    But i know that it is not a problem with the...
  6. Replies
    9
    Views
    1,523

    okay, the program is calculating probabilities...

    okay, the program is calculating probabilities but is very clunky so here is some pseudo-code:

    recurse(int i)
    for (x=0; x<12; x++)
    array[i]=x;
    temp = test()
    if(temp==0)
    ...
  7. Replies
    9
    Views
    1,523

    Recursion slows down mysteriously

    Hi, I'm using a recursive algorithm that seemed to work quite well when called from my main() function, but now i'm trying to run through different scenarios and when i call it from another function...
  8. Replies
    5
    Views
    3,554

    I'm using the Borland Command Line Compiler (not...

    I'm using the Borland Command Line Compiler (not sure what version, think it's pretty recent.) And I tried hard coding an example:

    cout<<pow10(1.2)<<' '<<pow10(.3);

    and it printed: 10 1

    And...
  9. Replies
    5
    Views
    3,554

    non-interger exponents

    Is there any way to use fractional exponents? I've tried:

    pow(base, exponent);
    with exponent being 1.2 or so and I've also tried a round-a-bout way to get the answer using:

    ...
  10. Replies
    12
    Views
    1,542

    I understand that, but is there a way to let the...

    I understand that, but is there a way to let the person type more then one character, say a sentence and then when they hit enter to let me process it one character at a time? I've thought of using...
  11. Replies
    12
    Views
    1,542

    using while(cin)

    help, i've spent many a desperate compile trying to tweak this code to get it to run but can't get it to work. The code looks like this:



    char letter;

    while(cin)
    {
    cin>>letter;
    // do some...
  12. Replies
    4
    Views
    938

    Yeah I know that the array with one entry is kind...

    Yeah I know that the array with one entry is kind of stupid but as far as i can figure, the .read function is designed to take in strings using arrays so i figured I should just adapt to it. When I...
  13. Replies
    4
    Views
    938

    specifics of a binary byte

    hi, I am trying to do something with particular bytes in a file, be it an .exe or .txt or any other kind, and I seem to have run into a problem. I'm using this code to get in the byte:


    char...
  14. Replies
    1
    Views
    1,615

    trying to read all asci char's in files

    Hi, I saw your encryption challenge and was a little intrigued by the option of being able to encrypt all asci files, and not just plain text, so I tried to do something similar with it myself....
  15. Replies
    2
    Views
    1,314

    Thanks all, Hammers place helped me fix the...

    Thanks all, Hammers place helped me fix the problem. Hammer, YOU ROCK!
  16. Replies
    2
    Views
    1,314

    compiler problems with borland

    hi, I was trying to compile my problem and after like fifty tries I finally got all the kinks out. Or so I thought. I am using Borland 2.5 or so, on the command line, and after it brought up the...
  17. Replies
    8
    Views
    1,390

    base 8 problem

    If you are in fact getting an error because of base 8 then you just have to specify decimal in your code. IE:

    NOT:


    cin>>number;


    But Instead:
Results 1 to 17 of 17