Search:

Type: Posts; User: s_ny33

Page 1 of 3 1 2 3

Search: Search took 0.01 seconds.

  1. Replies
    2
    Views
    2,028

    Missing something in dayofweek program

    I had to write a program that prompts the user for three integers representing the day, month, and year of a given date (e.g. 5 24 1994), and that displays the day of the week for the given date...
  2. Replies
    2
    Views
    1,122

    Custom header file

    Can someone tell me the proper outlay of a custom header file in C? Thanks
  3. Replies
    10
    Views
    2,384

    Ok...I got rid of the negatives but now I'm not...

    Ok...I got rid of the negatives but now I'm not getting the number of coins. For example, if I put 50.25 for purchase and 20.21 for payment, I get only the bills, 1 twenty and 1 ten but no change.
    ...
  4. Replies
    10
    Views
    2,384

    Thank you. One small issue. Now I get negative...

    Thank you. One small issue. Now I get negative numbers in my printf statement at the end. If I put total as say 20.00 and payment at 12.00, I get "-1 fives and -3 ones." They are all set to %d...
  5. Replies
    10
    Views
    2,384

    That was the question I posted. I'm not sure how...

    That was the question I posted. I'm not sure how to get the change.
  6. Replies
    10
    Views
    2,384

    Question on purchase and change program

    I'm trying to write this program that asks for the purchase amount, the payment amount and then outputs the change in the number of bills and coins. I think I'm missing an 'if' statement for...
  7. Thread: day of week

    by s_ny33
    Replies
    18
    Views
    6,023

    Can someone help me with how I should go about...

    Can someone help me with how I should go about how the inputted date is stored? Also, what I need to do to compute the century and year in part (c) of this problem? I would greatly appreciate any...
  8. Thread: day of week

    by s_ny33
    Replies
    18
    Views
    6,023

    Do I use an array for my scanf with a for loop?

    Do I use an array for my scanf with a for loop?
  9. Thread: day of week

    by s_ny33
    Replies
    18
    Views
    6,023

    Is this it... M = ((26 * month) - 2) /...

    Is this it...




    M = ((26 * month) - 2) / 10;
  10. Thread: day of week

    by s_ny33
    Replies
    18
    Views
    6,023

    Oh...I would replace 10 with month...right? Plus,...

    Oh...I would replace 10 with month...right? Plus, add the other paren.




    M = (26 * month) - 2)) / 10;
  11. Thread: day of week

    by s_ny33
    Replies
    18
    Views
    6,023

    OK...I'll take a look at the adjusted month. I...

    OK...I'll take a look at the adjusted month. I thought I may have to use a pointer to figure the year.
  12. Thread: day of week

    by s_ny33
    Replies
    18
    Views
    6,023

    Thanks for the advice AD but if I don't think...

    Thanks for the advice AD but if I don't think this through, I never learn C. Also, I think this assignment is looking for me to understand pointers (which is totally confusing to me) and probably...
  13. Thread: day of week

    by s_ny33
    Replies
    18
    Views
    6,023

    I don't know if you can consider this an attempt,...

    I don't know if you can consider this an attempt, but like I said, I don't know how to get this going.




    #include <stdio.h>
    #include <stdlib.h>
  14. Thread: day of week

    by s_ny33
    Replies
    18
    Views
    6,023

    day of week

    Can anyone help me with this program. I don't even know where to start with this one. I really want to learn this so I'm not looking for complete code, just some guidance to help this rookie ...
  15. Replies
    11
    Views
    1,741

    Thanks for all your advice. I really appreciate...

    Thanks for all your advice. I really appreciate it.
  16. Replies
    11
    Views
    1,741

    OK...first thing...cbastard...i don't drink....

    OK...first thing...cbastard...i don't drink. Maybe I should start though...maybe I'll write better code. So thanks for the advice. I've come to realize us newbies are susceptible to punishment....
  17. Replies
    11
    Views
    1,741

    I changed my code and I get the following erros:...

    I changed my code and I get the following erros:

    sum.c: In function `main':
    sum.c:30: warning: format argument is not a pointer (arg 2)
    sum.c:43: warning: passing arg 1 of `findmax' makes...
  18. Replies
    6
    Views
    1,904

    Sorry...I was responding to the second poster...

    Sorry...I was responding to the second poster first. I tried yours and it worked. I had to move the -o in the syntax. The -o went between somefile.c and somefile.exe. I then included what you stated...
  19. Replies
    6
    Views
    1,904

    Thanks...I tried the gcc prog.c -o prog.ex >...

    Thanks...I tried the

    gcc prog.c -o prog.ex > somefile.txt

    ...and it created the file but the file was empty. I tried looking at their documentation too and I couldn't find anything either. I'm...
  20. Replies
    6
    Views
    1,904

    gcc compiler question

    does anyone know the command line syntax for the gcc compiler to output the compiler errors to a file?
  21. Replies
    11
    Views
    1,741

    question about an array

    I'm writing a program that prompts for ten integers, then stores these intergers in an array. Then the program computes and stores the sum and the largest and smallest of these integers. The program...
  22. Replies
    16
    Views
    6,014

    Oh no...not only does it return 1.000000 for the...

    Oh no...not only does it return 1.000000 for the %f in my printf, but if I input 357, it returns the statement for water and not mecury. What am I doing wrong?
  23. Replies
    16
    Views
    6,014

    Here is the code: /* Filename: ...

    Here is the code:




    /*
    Filename: range.c

    Description: Displays a substance if the observed boiling point is
    within 5% of the expected boiling point.
  24. Replies
    16
    Views
    6,014

    OK...thanks. Why is the first %f in my printf...

    OK...thanks. Why is the first %f in my printf statement return 1.000000 if the user inputs 97 ("data" variable)? Why doesn't this display 97?
  25. Replies
    16
    Views
    6,014

    That did it...thanks. Now I'm trying to do some...

    That did it...thanks. Now I'm trying to do some formatting of my output but I get parse errors. Can someone tell me what is wrong with this? I addedd some words to the printf statement to make more...
Results 1 to 25 of 60
Page 1 of 3 1 2 3