Product Of Even numbers [HELP]

Please support our C advertiser: Programming Forums - DaniWeb Sister Site
Thread Solved

Join Date: Jun 2007
Posts: 11
Reputation: mnmustafa is an unknown quantity at this point 
Solved Threads: 0
mnmustafa mnmustafa is offline Offline
Newbie Poster

Product Of Even numbers [HELP]

 
0
  #1
Jun 2nd, 2007
Hiz well i m new in here n i m goin to have exam after 3 days i got stuckd in a question
Q) Write a program to print the product of even numbers.....

plz i m new with c langauge n i m having final exam jst after 3 DAys
thnx
Reply With Quote Quick reply to this message  
Join Date: May 2004
Posts: 178
Reputation: jim mcnamara is on a distinguished road 
Solved Threads: 10
jim mcnamara jim mcnamara is offline Offline
Junior Poster

Re: Product Of Even numbers [HELP]

 
0
  #2
Jun 2nd, 2007
What code have you written so far?
Reply With Quote Quick reply to this message  
Join Date: Jun 2007
Posts: 11
Reputation: mnmustafa is an unknown quantity at this point 
Solved Threads: 0
mnmustafa mnmustafa is offline Offline
Newbie Poster

Re: Product Of Even numbers [HELP]

 
0
  #3
Jun 2nd, 2007
Actually i havent started yet......i saw the question in exercise n i didnt found any example in my book....so thats y i asked it here
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 1,546
Reputation: Ene Uran has a spectacular aura about Ene Uran has a spectacular aura about 
Solved Threads: 174
Ene Uran's Avatar
Ene Uran Ene Uran is offline Offline
Posting Virtuoso

Re: Product Of Even numbers [HELP]

 
0
  #4
Jun 2nd, 2007
This will show the even integers between 2 and limit, then it is up to you to show the product:
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5. int x;
  6. int limit = 30;
  7.  
  8. for(x = 2; x <= limit; x=x+2)
  9. {
  10. printf("%d\n", x);
  11. }
  12.  
  13. getchar(); // wait for enter
  14. return 0;
  15. }
drink her pretty
Reply With Quote Quick reply to this message  
Join Date: Jun 2007
Posts: 11
Reputation: mnmustafa is an unknown quantity at this point 
Solved Threads: 0
mnmustafa mnmustafa is offline Offline
Newbie Poster

Re: Product Of Even numbers [HELP]

 
0
  #5
Jun 2nd, 2007
Thankyou
Reply With Quote Quick reply to this message  
Join Date: Jun 2007
Posts: 11
Reputation: mnmustafa is an unknown quantity at this point 
Solved Threads: 0
mnmustafa mnmustafa is offline Offline
Newbie Poster

Re: Product Of Even numbers [HELP]

 
0
  #6
Jun 4th, 2007
but tis showing 143254346436 lolz ,..........i mean some numbers.......
Reply With Quote Quick reply to this message  
Join Date: Apr 2006
Posts: 5,051
Reputation: John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold 
Solved Threads: 332
Team Colleague
John A's Avatar
John A John A is offline Offline
Vampirical Lurker

Re: Product Of Even numbers [HELP]

 
0
  #7
Jun 4th, 2007
Post your code.
"Technological progress is like an axe in the hands of a pathological criminal."

All my posts may be freely redistributed under the terms of the MIT license.
Reply With Quote Quick reply to this message  
Join Date: May 2007
Posts: 7
Reputation: sweetleaf is an unknown quantity at this point 
Solved Threads: 0
sweetleaf sweetleaf is offline Offline
Newbie Poster

Re: Product Of Even numbers [HELP]

 
0
  #8
Jun 6th, 2007
well after this u only have to print the product so create a new variable long prefferably to store x*x and print tht outside the loop
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC