Search:

Type: Posts; User: SilentPirate007

Page 1 of 2 1 2

Search: Search took 0.00 seconds.

  1. Replies
    6
    Views
    15,134

    :) sorry, didn't expect to find it there....

    :) sorry, didn't expect to find it there....
  2. Replies
    6
    Views
    15,134

    Thanks for the help, problem is solved. @Quzah...

    Thanks for the help, problem is solved.

    @Quzah lol - I have actually no idea [rather stupid now that I think about it..]

    @Adak thanks for your advice -- I actually use spaces of 3, because the...
  3. Replies
    6
    Views
    15,134

    Sum of all elements in an array

    Hello,

    I have recently been introduced to arrays, but I cannot seem to get this program to calculate the sum of all elements correctly:



    #include <stdio.h>
    int main()
    {
    int i, m,...
  4. Replies
    6
    Views
    11,635

    I have to use 2 functions largest() and...

    I have to use 2 functions largest() and smallest()....
  5. Replies
    6
    Views
    11,635

    Largest and smallest of 3 inputs

    Hello,

    I am having a problem with this particular program. The user is prompted to insert 3 numbers (integers). The program should check which of the 3 is the largest and which is the smallest.
    ...
  6. Right, well, I found that the quickest and...

    Right,

    well, I found that the quickest and shortest way was to use NeonBlacks' method.
    I added <windows.h> and beneath my statement, I put: Sleep(3000);
  7. It's for a practical joke (under normal...

    It's for a practical joke (under normal circumstances, I wouldn't imagine a reason for it either).
  8. Thanks, I'll look into it.

    Thanks, I'll look into it.
  9. Set delay time between printf() statements

    Hello,

    I was wondering if it was possible to set, for example, a 3 second delay between printf() statements?

    Example:

    Please enter your age: 35

    >3 second delay<
  10. yes it is for school, I have to use functions..(I...

    yes it is for school, I have to use functions..(I could have used an easier method, but the focus is design)

    I will only be graded on whether it works or not (not what it looks like)...

    The...
  11. Forgot to mention, I suspect the problem area to...

    Forgot to mention, I suspect the problem area to be:



    }
    void largest()
    {
    int large;

    printf("Among the numbers you entered\n");
  12. Determine the largest and smallest of three integers

    I have just been introduced to a new chapter in C and I'm a bit confused/lost.

    I'm constructing a program that will prompt the user for three integers and then determine the largest and the...
  13. Replies
    15
    Views
    5,743

    I forgot to add, I can only use the standard...

    I forgot to add, I can only use the standard input output library <stdio.h>. sqrt(number) requires <math.h> or at least won't work with stdio.h.

    Since some seem to find it hard to read, could...
  14. Replies
    15
    Views
    5,743

    Prime Numbers

    I'm busy with a code that should determine whether a certain value is a prime number or not. If the number isn't prime, it should determine the smallest divisor of that value. Unfortunately, I'm...
  15. Mathematical concept for prime numbers

    Hello,

    I'm looking for a mathematical algorithm, that I can use as a guideline for a code I'm busy with.

    I'm looking for a very basic mathematical algorithm which will determine whether a...
  16. Replies
    1
    Views
    2,678

    Filtering the return key

    I would like to know if it is possible to filter all return key inputs after the first. This at least until the next scan function or getchar() etc...?
  17. Replies
    1
    Views
    815

    Compile (windows app n00b)

    I would like to know how to turn a C source code into a windows graphical application. I´m using Devcpp, but VB could also do....

    If you have any links to good tutorials or if you don't mind...
  18. Replies
    13
    Views
    13,189

    Well...The below code works just fine, but when I...

    Well...The below code works just fine, but when I implement the advised code, that would just loop until I break it off...

    The code that works:



    #include <stdio.h>

    int main()
    {
  19. Replies
    13
    Views
    13,189

    I also tried to compile it for test purposes and...

    I also tried to compile it for test purposes and it doesn't end the loop with any of the input I give.
  20. Replies
    13
    Views
    13,189

    Just want to make sure since any negative integer...

    Just want to make sure since any negative integer could exit the loop - not just (-1).

    Shouldn't it be (or am I perhaps overlooking something):


    }while(scanf("%d", &user_input)!<=-1); // If...
  21. Replies
    13
    Views
    13,189

    Excellent... Those are the type of tips I was...

    Excellent... Those are the type of tips I was hoping for!!

    Thank you very much!
  22. Replies
    4
    Views
    1,495

    Ok, but the problem still remains that if the...

    Ok, but the problem still remains that if the user wants to try again, it exits the loop.

    The code does, however, need some more fixing, because at the moment even the right answer is wrong when...
  23. Replies
    4
    Views
    1,495

    not looping after if()

    I received a chain email (arghhh) recently and I thought I would try and make a program out of this particular one for practice.

    The point of the program is to figure out the pattern for a few...
  24. Replies
    13
    Views
    13,189

    I managed to get it working with everyone's...

    I managed to get it working with everyone's advise. Thanks

    Is there any unnecessary code within the program?



    #include <stdio.h>

    int main()
    {
  25. Replies
    13
    Views
    13,189

    Average of user inputs (in a loop)

    My problem is I'm not sure how to get the program to identify each user input uniquely (in a loop). I suppose it would have been a lot easier if the users input, in this particular program,was fixed...
Results 1 to 25 of 34
Page 1 of 2 1 2