#include <iostream>
using namespace std;
int main()
{
int a,tpl=0;
cout <<"bir sayi girin :";
cin >> a;
for(int i=1;i<=a;i++)
{
cout << i <<"\n";
tpl=tpl+i;
}
cout << tpl;
}
#include <iostream>
using namespace std;
int main()
{
int a,tpl=0;
cout <<"bir sayi girin :";
cin >> a;
for(int i=1;i<=a;i++)
{
cout << i <<"\n";
tpl=tpl+i;
}
cout << tpl;
}
0 Yorumlar