answersLogoWhite

0

#include<stdio.h>

#include<conio.h>

void main()

{

int c=1,i;

unsigned int s=0;

clrscr();

for(i=1,(i<=15;i++))

{

if(i%2==0)

{

s=s+i;

c=c+i;

}

}

printf("/n sum of the first 15 even numbers is%d",s);

printf("/n square of the sum is: %d",(s*s));

getch();

}

User Avatar

Wiki User

13y ago

What else can I help you with?

Related Questions

Write a c program to accept a numbers and generate square root cube and exponential values?

write a c program to accept a number and generate a square root cube and exponential values


How do you write Square program using vb?

write a vb program to find the magic square


Write a C program to find the square of two numbers?

Please visit http://talentsealed.blogspot.com/2009/10/to-find-sqaure-of-numbers-using-c.htmlfor the answer.


How do you write square numbers?

normally


Program in 'c' to find the LCM of any given five numbers?

Just write a method or function that calculates the LCM for two numbers at a time. Then calculate the LCM for the first two numbers, get the LCM of the result with the third number, etc.Just write a method or function that calculates the LCM for two numbers at a time. Then calculate the LCM for the first two numbers, get the LCM of the result with the third number, etc.Just write a method or function that calculates the LCM for two numbers at a time. Then calculate the LCM for the first two numbers, get the LCM of the result with the third number, etc.Just write a method or function that calculates the LCM for two numbers at a time. Then calculate the LCM for the first two numbers, get the LCM of the result with the third number, etc.


Write a program in Lex to eliminate white space and collect numbers as a token?

write a lex program to delete space from the program


How do you write an assembly language program to find the sum of n numbers using array?

write an assembly language program to find sum of N numbers


How do you write a program to find out the square and cube of first ten natural numbers in gw basic?

First you will need to have some basic programming knowledge. You can use this to help make the program that is needed.


How do you write a program to find the area of a square in qbasic?

To write a program in QBASIC to find the area of a square, you first need to prompt the user to enter the length of one side of the square. You can then calculate the area by squaring the length (multiplying it by itself) and finally display the result. Here's a simple example: INPUT &quot;Enter the length of the side of the square: &quot;, side area = side * side PRINT &quot;The area of the square is: &quot;; area


Write a program to calculate first?

int first= 1;


Write a program to input two numbers and print their number and square?

Here's a simple Python program that takes two numbers as input and prints each number alongside its square: # Input two numbers num1 = float(input(&quot;Enter the first number: &quot;)) num2 = float(input(&quot;Enter the second number: &quot;)) # Print each number and its square print(f&quot;Number: {num1}, Square: {num1**2}&quot;) print(f&quot;Number: {num2}, Square: {num2**2}&quot;) This program uses the input function to read numbers, converts them to floats, and then calculates and displays their squares.


Shell program for gcd of three given numbers?

write a shell program for finding out gcd of three given numbers? write a shell program for finding out gcd of three given numbers? write a shell program for finding out gcd of three given numbers? check bellow link http://bashscript.blogspot.com/2009/08/gcd-of-more-than-two-numbers.html