Search:

Type: Posts; User: engstudent363

Search: Search took 0.00 seconds.

  1. How do you check how many characters a user has entered?

    Lets say I have the code below. This program example would ask the user to enter a string of characters, then save those characters into an array named "s1". How can I find out how many characters...
  2. Replies
    4
    Views
    1,056

    Well sometimes it prints out more than one I'm...

    Well sometimes it prints out more than one I'm guessing because %c does something special. What does %c do or mean?
  3. Replies
    4
    Views
    1,056

    Need help %c ???

    I'm reading in a book and it gave an example where there was a line of code looking like this:


    printf("%c", '*');

    This prints a certain amount of * but I don't know where it gets the...
  4. Need help with a program, theres something in it for you

    I've been stuck on this program trying to get it to work for the past 2 days and haven't gotten it to run properly. I have no idea what I need to do and I need some serious help. If someone can get...
  5. Replies
    4
    Views
    2,549

    thank you sirs

    thank you sirs
  6. Replies
    4
    Views
    2,549

    Need help to show decimals

    I know that I use "float" but where do I place the word float so that my program output shows decimals. Right now the program just cuts the decimals off. This program stores how many of each product...
  7. Replies
    2
    Views
    1,386

    Need help, nested loops

    I'm completely stuck. I've thought about this for probably about 4 hours now and can't think of a way to do it. Could someone tell me what I need to do. Here's what I'm trying to accomplish:

    Write...
  8. Replies
    4
    Views
    1,077

    Need help with "Switch"

    Ok, I was given an assignment that looks like this:

    In a menu, ask the user whether they want to calculate the factorial of a non-negative number, or exit. If they choose to calculate the...
  9. Replies
    3
    Views
    1,125

    What is the "switch" function?

    Can someone describe to me what a "switch" does?
  10. Replies
    7
    Views
    1,127

    Any advice?

    I want to calculate the factorial of a number and have the results printed on the screen. If the number is -1 the program will exit. If the number is less than -1 the program will give an error...
  11. Replies
    5
    Views
    1,222

    Also, Is there a command that tells the program...

    Also, Is there a command that tells the program to go back to the beginning of the program? Because if the number entered is a negative number then the program exits the while loop and goes to the...
  12. Replies
    5
    Views
    1,222

    I know what a factorial means, such as if I was...

    I know what a factorial means, such as if I was given 5! that would mean 5*4*3*2*1 but I don't know how to implement that into my program so that the computer knows to do that.
  13. Replies
    5
    Views
    1,222

    Need help!

    Assignment:

    Part 1: Write a program that requires the user to input a non-negative number and then calculates the factorial of that number and prints the result to the screen. Use a while loop to...
  14. Replies
    5
    Views
    1,958

    I'm having trouble figuring out how to have the...

    I'm having trouble figuring out how to have the computer calculate a number's factorial and then display it. Also after you enter a negative number I don't know how to return back to the while loop...
  15. Replies
    5
    Views
    1,958

    Need help on one of my assignments

    I was given this assignment but I'm not really sure where to start. Could someone give me some ideas?

    Assignment:

    Part 1: Write a program that requires the user to input a non-negative number...
Results 1 to 15 of 15