Got it! Thanks! :)
Type: Posts; User: bummielove
Got it! Thanks! :)
Hello again guys!
So I've been working on a program that accepts 2 inputs a & b
and does the following:
Get another b number of inputs ,may contain negative nos and
print the largest and the...
Noted! :)
I got it. thanks to all those who helped. :) YAAAAAAAAY! :D
Here's my code
counter = 2;
ans1=a;
while (counter <=b)
{
ans1 = ans1 + a;
counter++;
when does one set a counter = 0 and =1?
Last one : I really find loops confusing. :|
counter = 0;
ans1=a;
while (counter <=b)
{
ans1 = a + ans1;
b++;
add "a" "b" times.
so for example, a=3 and b =2
ans = 3+3.
My problem is how to begin the loop. :(
while(x<=b)
{
e1=e1+a;
x++;
}
for(x=1;x<=a;x++)
e2=e2*x;
for(x=1;x<=b;x++)
e3=e3*a;
Thank you. :)
Honestly, I dont know what to do. :(
hi guys. im having a hard time figuring this out. could someone help me please?
How could I write the code for
Product of a & b with the use of addition operator only.
Thanks. :)
#include <stdio.h>
int main ()
{
int x = 1, y = 1, b;
printf("What value for b did you enter? ");
scanf("%d", &b);
Oh.... Sorry bout that. Thank you. Such a genius, (.m^m.)
That didn't helped. That was a practice code. Of course I know how to count.
counter = 1;
b = 1;
do {
printf("%d\n", counter);
}while (counter <=b);
b++;
This. :) It only prints single numbers.
Here is something that I can't figure out... How can I make a program that prints a
Number triangle with height = b
Example: b=5
Output is
55555
4444
333
22
1
Should I use int void ?
OKAY GUYS.... I'm a bit confused. Which should I use now? :)
Thank you for the tip! THAAAAAAAAANKS! :)
Thank You Sir!
That's what I needed! Thank you Tim S! \m/ Thanks! Thanks to those who helped me here! :)
When I'm trying to run the program, it keeps on displaying " error: called object 4 is not a function" There.
Thanks! :)
When I'm trying to run the program, it keeps on displaying " error: called object 4 is not a function" There.
Beginner here. This is the first program I made. There seems to be an error. Please help me fix it. Thanks.
#include <stdio.h>
int main()
{
int a, b, c, ans1, ans2, ans3, ans4, ans5;...