C/C++ Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 



Go Back   Dev Articles Community ForumsProgrammingC/C++ Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old March 17th, 2014, 01:56 PM
rmaxhuni rmaxhuni is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Mar 2014
Posts: 1 rmaxhuni User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 9 m 23 sec
Reputation Power: 0
General - C++ Help

Where is mistake in this program
#include <iostream.h>
int main()


{
int n,m;
double x,y,shuma;
cout<<"Te ipen vlerat e n,m dhe x:";
cin>>n;
cin>>m;
cin>>x;
y=2*x+4*shuma(3,n+2,4,1,4)+shuma(4,2*n,6,m,3)+shum a(5,n,n+1,n-2,-7);
cout<<"Shuma e fituar eshte y="<<y<<endl;
return 0;
};

double shuma(int a,int b,int c, int d,int e)
{
int i,j;
double f,s;
f=1;
s=0;
for(i=a;i<=b;i++)
{
if(i==c)
{i=i+1;}
else
{
for(j=1;j<=d;j++)
{
f=f*j;
}
s=s+(f+(e*i));
}
}
return s;
}

Reply With Quote
  #2  
Old March 19th, 2014, 11:34 PM
bal7 bal7 is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Mar 2014
Posts: 1 bal7 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 15 m 6 sec
Reputation Power: 0
Regarding mistake in the program



The "Shuma" may not be a variable name.
The term y= does not evaluate to a function
"The Shuma e ftaur eshte y=< is not a complete code

Thanks.

:)

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingC/C++ Help > General - C++ Help


Developer Shed Advertisers and Affiliates


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.

© 2003-2018 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap