Could someone please explain exactly what the for statement in this problem is doing step by step?
#include <stdio.h>
#include <string.h>
int main()
{
char string[100],...
Type: Posts; User: benrogers
Could someone please explain exactly what the for statement in this problem is doing step by step?
#include <stdio.h>
#include <string.h>
int main()
{
char string[100],...
Thanks a lot cas, jimblumberg and itsme86!
I would like to create a program where a user inputs their first and last name and the program say it to the user, but my program is only showing the first name.
Any help is greatly appreciated....
is the square roote function eg: b= a * a, c = b / a ?
this is what I have so far
int main ()
{
double d, mult, asqrt;
printf("Please enter in a double: \n");
scanf("%f", &d);
Yes what does
void count_to_ten ( int count ) even mean?
Is it possible without using any standard library functions, to create a function called asqrt that calculates the square root of a double. Then create a program (this is the same question) that...
I've read 10 recursion tutorials and they are all based on the same examples. Does anyone know how I can change my code to output all the numbers not just to 1st?
I am looking for my program to do...
So I just read the tutorial and it was no help. PLEASE EXPLAIN!!
Without using any loops, I need to create a function that will use recursion to print all the multiples of a given number up to any limit given (the limit will be given to the function by the...
Thanks for the help
for (b = a; b < 1000; b += a)
Works like a charm!!
I need to create a program using a for loop that will read in an integer, and print all the multiples of that integer up to 1000. e.g. given 7, will print 7, 14, 21, 28...(until the end)
This is...
Alright fixed that.
Updated code:
#include <stdio.h>
int main()
Thanks for this.
- when entering either 1,2 or 3 it always says the number is either odd or even.
- when entering 1 it does not show the remainder.
when the number 3 is entered everything is...
#include <stdio.h>
int main()
{
int x, y, z;
double d;
printf("Please enter in 1, 2 or 3: ");
scanf("%d", &x);
first off my program wont even compile.
I have to create a program that takes one integer (the value of the integer will be 1, 2, or 3). The program behaves differently depending on the value of the integer. If the number is 1, then get...
I have to write a program that takes one integer and follows these rules. First, print this number. When the number is even, change the number to itself divided by 2. Print the resulting number. ...
Thank you for for this. I appreciate the comments.
Can you please explain the while loop?
I have to create a program that will read integer numbers from the user, one at a time. It will print these numbers out after reading them. It will continue to read numbers until it receives the...
bold does the trick.
#include <stdio.h>
int main()
{
int x, y, z;
I have to create a program that takes 2 numbers. If the first number is equally divisible by the second number, then print the number of times it's divisible, otherwise, print a message saying "not...
c) 4.5 is the answer.
int main()
{
int x = 5;
double d = 3.5;
double y = 2;
while (x > 3)
{
printf(“%d\n”, x);
d += (x % 2);