Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


Write a programe print the sum of series 0,1,2,.....10

Answers were Sorted based on User's Feedback



Write a programe print the sum of series 0,1,2,.....10..

Answer / nithya

#include<stdio.h>
main()

{
int i,sum=0;
printf("sum of the series is");
for(i=0;i<10;i++)
{

sum=sum+i;
printf("%d",sum);
}

Is This Answer Correct ?    16 Yes 5 No

Write a programe print the sum of series 0,1,2,.....10..

Answer / athiyaman

#include<stdio.h>
void main()
{
int i,sum=0;
for(i=0;i<=10;i++)
sum=sum+i;
printf("sum=%d",sum);
}

Is This Answer Correct ?    6 Yes 0 No

Write a programe print the sum of series 0,1,2,.....10..

Answer / manjushree

Answer #2 doesnot count for integer 10.

int main()
{
int i,temp=0;
printf("sum of series is:");
for(i=0;i<10;i++)
temp+=i;
printf("%d",temp);
getch();
}

Is This Answer Correct ?    3 Yes 2 No

Write a programe print the sum of series 0,1,2,.....10..

Answer / akash patil

#include<stdio.h>
voind main()
{
int n=10;
printf("sum is %d",n*(n+1)/2;
getch();
}

Is This Answer Correct ?    1 Yes 0 No

Write a programe print the sum of series 0,1,2,.....10..

Answer / mrs.ahmer

#include<stdio.h>
#include<conio.h>
void main()
{
int c,sum;
clrscr();
c=0;
sum=0;
while(c<=10)
{
printf("%d\n",c);
sum=sum+c;
c=c+1;
}
printf("sum is %d",sum);
getch();
}

Is This Answer Correct ?    0 Yes 0 No

Write a programe print the sum of series 0,1,2,.....10..

Answer / sevak.yatrik777

main()
{
int i;
printf("sum of series is:");
for(i=0;i=10;i++)
i=i+i;
scanf("%d",&i);
printf("%d",i);
}

Is This Answer Correct ?    0 Yes 0 No

Write a programe print the sum of series 0,1,2,.....10..

Answer / s.m.jyo

main()
{
int i;
printf("sum of series is:");
for(i=0;i=10;i++)
i=i+i;
scanf("%d",&i);
printf("%d",i);
}

Is This Answer Correct ?    7 Yes 9 No

Post New Answer

More C Interview Questions

Question 1: You want to conduct a survey within your classroom, on the quality of canteen’s food. You ask each of your class fellows to rank the quality of food between 1 and 5 (1 representing excellent quality and 5 representing worst quality). During the survey, you make a list containing the roll# of student and the opinion given by that student. The list can be as follow Roll # Opinion 234 1 235 1 236 5 237 1 238 2 239 3 240 5 241 5 242 1 To get the results of the survey, you need to determine the frequency of each opinion value. The frequency of an opinion is determined by counting the number of students giving that opinion. For example, for the above list the frequency of opinion value 1 is 4 and frequency of opinion value 4 is 0. After getting the frequency of each opinion, you can easily judge about the quality of the food by seeing through the frequency of each opinion. You need to develop a program to calculate the results of this survey. The program inputs the opinion of 50 students and counts the frequency of each opinion. It then displays a report showing the frequency of each opinion. Sample output: Opinion Frequency Remarks 1 5 Excellent 2 10 Good 3 15 Normal 4 10 Bad 5 10 Really bad

1 Answers  


without a terminator how can we print a message in a printf () function.

7 Answers   NIIT,


write a program in c language to print your bio-data on the screen by using functions.

6 Answers   College School Exams Tests, IBM,


write a program in c language that uses function to locate and return the smallest and largest integers in an array,number and their position in the array. it should also find and return the range of the numbers , that is , the difference between the largest number and the smallest.

1 Answers  


how many keywords are available in 'c' language a) 32 b) 34 c) 45 d) 48

1 Answers  


can we print any string in c language without using semicolon(;)(terminator) in whole program.

11 Answers  


What are formal parameters?

0 Answers  


Difference between data structure and data base.

7 Answers   CTS, Value Labs, Zoho,


What is the value of c?

0 Answers  


what is the difference between north western polytechnique university and your applied colleges?? please give ur answers for this. :)

0 Answers  


What is the use of a static variable in c?

0 Answers  


Why do some versions of toupper act strangely if given an upper-case letter?

0 Answers  


Categories