Prepare for your Next Interview
|
Welcome to the Geeks Talk forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact contact us. |
This is a discussion on fibonecii series in C++ within the C and C++ forums, part of the Software Development category; when we display the series as 0,1,1,2...34 after that how we calculate the sum and average of this fibonecii seris...
|
|||||||
|
|||
|
Re: fibonecii series in C++
i = 0;
sum = 0; n = 0; while (i <= 34) { printf ("%d",i); j = i; i = i + j; n++; sum = sum + i; } printf("Sum is %d",sum); printf("Avg is %f",sum/n); |
![]() |
|
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Number Series [2].... | psuresh1982 | Brainteasers | 14 | 07-09-2009 09:30 AM |
| Complete the Series | Manojks | Brainteasers | 31 | 10-13-2008 12:22 PM |
| what comes next in this series..... | psuresh1982 | Brainteasers | 13 | 02-15-2007 04:46 AM |
| series... | anchal gupta | Brainteasers | 10 | 01-12-2007 07:54 AM |
| Number series [1].... | psuresh1982 | Brainteasers | 8 | 01-10-2007 01:28 AM |