write a program to display the result of the following summation
- 2021-02-12
توصيف
write a program to display the result of the following summation:
1+2+3+4+5+6+7+8+9
=====================================
solution:
int summation=0;
for(int i =1;i<=9;i++)
{
summation=summation+i;
}
System.out.println("result of summation is "+summation);