Search:

Type: Posts; User: Swordsman

Page 1 of 2 1 2

Search: Search took 0.01 seconds.

  1. Replies
    8
    Views
    1,215

    I'm pretty sure that I answered this within the...

    I'm pretty sure that I answered this within the absolute first paragraph (and the program is actually C++ that uses this method because it's quicker):





    No, my first port of call was looking...
  2. Replies
    8
    Views
    1,215

    You suggest that I should learn C# by some other...

    You suggest that I should learn C# by some other way apart from programming in C#? Should I give Go a bash to see if it helps instead?
  3. Replies
    8
    Views
    1,215

    File Reading Help

    Hi all,

    My C# is VERY basic, but I've been given the task of converting a C++ program into C# anyway. This part of the program is pretty simple, and is trying to read a certain amount of bytes...
  4. Replies
    7
    Views
    1,296

    I've changed the initial array to include 0 and 1...

    I've changed the initial array to include 0 and 1 to match the positions of the vector up.

    Thanks for the help anon, here is the finished code:



    vector<int> primes;

    int n, numToCheck;
  5. Replies
    7
    Views
    1,296

    Thanks for your continued help. My second for...

    Thanks for your continued help.

    My second for loop has changed to:



    for(int j = numToCheck; j < primes.size(); j += numToCheck)


    though I am still wondering how to mark the numbers in...
  6. Replies
    7
    Views
    1,296

    Thanks for the comments. I was using two...

    Thanks for the comments.

    I was using two vectors as the plan was to remove them as I go, and not just mark them, which looking at the algorithm, is the wrong way to do it. I started with the...
  7. Replies
    7
    Views
    1,296

    Deleting Vector objects in a for loop

    Hi all,

    I am currently trying to implement a Sieve of Eratostheneses in C++ as part of a book I am learning. The objective is to find all of the prime numbers between 1 and n in a list. To...
  8. Replies
    153
    Views
    693,149

    Sticky: Has anyone mentioned Bjarne Stroustrup's P3 book...

    Has anyone mentioned Bjarne Stroustrup's P3 book yet?

    After purchasing many, many books focusing on learning C++, I still rate this as the best. Hell, I happen to think that this is the best...
  9. Replies
    38
    Views
    3,674

    So, when exactly would one use the Creature...

    So, when exactly would one use the

    Creature creature;
    Creature creature = new Creature();
    Creature* creature

    initialisations?

    Can anyone think of any use cases to split up how you would...
  10. Replies
    0
    Views
    2,466

    OpenFileDialog and MSDN

    Hi all,

    I'm just trying to learn Visual C++ and I'm having a problem with the OpenFileDialog control. I'm trying to drag out the filename selected in to a text box, but MSDN has given me broken...
  11. Replies
    2
    Views
    2,027

    DirectX 9.0c Common Files folder

    Hi all,

    I have a quick question about DX9. I have recently started with it after a while using OpenGl, kinda trying to expand my knowledge base a bit. Anyway, I downloaded the DXSDK (June 2008)...
  12. Replies
    1
    Views
    3,477

    extern classes

    Hi all,

    I have a quick question on the usage of the extern keyword. I'm trying to get a variable to be of global scope, but as it is of a custom type, I'm not sure how to use extern and Google...
  13. Replies
    6
    Views
    3,608

    Thanks, can you explain what this does though...

    Thanks, can you explain what this does though please as I'm a bit confused :P
  14. Replies
    6
    Views
    3,608

    I'm familiar with modular arithmetic already but...

    I'm familiar with modular arithmetic already but I'm not sure how to implement a mod 26 function inside the code.

    As I'm using ASCII to shift the letters, could I just say something like:


    ...
  15. Replies
    6
    Views
    3,608

    Another Caesar Cipher

    Hello,

    I'm currently learning C++ and have decided to write a Caesar implementation. I have the code working but lack error checking (dealing with spaces, going back to start of alphabet) and am...
  16. Replies
    24
    Views
    5,213

    Thanks for the help everybody. For those who...

    Thanks for the help everybody. For those who were interested, I went with a combination of Salem's and Bubba's answers.

    The easiest way of explaining to him was to first tell him why computers...
  17. Replies
    24
    Views
    5,213

    Interesting Question

    Hi all,

    I've got a question which I didn't know how to answer, and where else to post it.

    I program pretty much everyday and recently, my 5 year-old nephew has been sitting with me and asking...
  18. Replies
    31
    Views
    8,056

    I'd completely forgottten about the Atari ST! ...

    I'd completely forgottten about the Atari ST! While I didn't use it to program, it was a great gaming rig. I still wonder how many hours were wasted on that playing Bubble Bobble and Elite instead...
  19. Thread: help plz

    by Swordsman
    Replies
    11
    Views
    1,321

    If you're using DevC++ or a similar IDE, you...

    If you're using DevC++ or a similar IDE, you might want to think about putting getch() in there so you can actually see the result without having to run it from command line.



    printf("&#37;d...
  20. Replies
    31
    Views
    8,056

    How did you begin?

    After reading the Windows 3.1 thread, I got thinking. How did all of you start out in your programming endeavours?

    What was the first language you used and how did it happen?

    As I mentioned, I...
  21. Replies
    14
    Views
    5,647

    Thanks to twomers for saving me. I thought I...

    Thanks to twomers for saving me. I thought I made a terrible mistake then :)
  22. Replies
    30
    Views
    6,655

    I've still got a copy of Windows 3.11 for...

    I've still got a copy of Windows 3.11 for Workgroups on an old Compaq Laptop!
    I use it for when SEGMENTATION FAULT! and such things give me a headache and I want to play about in QBasic.

    I still...
  23. Replies
    18
    Views
    2,723

    I would imagine that Deimus is using either...

    I would imagine that Deimus is using either Visual C++ or DevC++ to write C code as it automatically saves it to a cpp extension. If you are being asked to save a C file as the cpp format, I would...
  24. Replies
    9
    Views
    1,472

    I edited the current code in to the top post. ...

    I edited the current code in to the top post.

    The input file is just literally a text file with the words "hello middle middle end" inside.
  25. Replies
    9
    Views
    1,472

    *Fixed* I had already taken out the free the...

    *Fixed*
    I had already taken out the free the tree/close file after I had posted, as it was one of those things that I had played with and not taken out. The fscanf I completely missed :)


    ...
Results 1 to 25 of 39
Page 1 of 2 1 2