/* File: sumn.c
Computes either a sum of integers or a sum of 1/integers or 0
*/
Assignment: 4
Programmer: Chukwu Ugochukwu D.
Date: October 7, 2011
Question: 1
DalID: B00556842
Course: ENGM 1081
#include <stdio.h>
#include <stdlib.h>
int main(void)
cfw_

Assignment 5
1
Department of Engineering Mathematics and Internetworking
COMPUTER PROGRAMMING
ENGM 1081
ASSIGNMENT 5
Due Date: Monday, October 19, 2015, 10:00 am
1. Write a program sumsquares.c which reads floating point numbers from the file sumsquaresin

Assignment 3
1
Department of Engineering Mathematics and Internetworking
COMPUTER PROGRAMMING
ENGM 1081
ASSIGNMENT 3
Due Date: Monday, October 5, 2015, 10:00 AM
1. Suppose that at a particular steel mill, steel bars are grouped into classes according to t

Assignment 7
1
Department of Engineering Mathematics and Internetworking
COMPUTER PROGRAMMING
ENGM 1081
ASSIGNMENT 7
Due Date: Monday, November 2, 2015, 10:00 am
1. If you are in a city and have to walk from where you are, having planar coordinates (0, 0)

Assignment 2
1
Department of Engineering Mathematics and Internetworking
COMPUTER PROGRAMMING
ENGM 1081
ASSIGNMENT 2
Due Date: Monday, September 28, 2015, 10:00am
1. Write a program which reads a car license plate and then prints the result to the screen.

Assignment 10
1
Department of Engineering Mathematics and Internetworking
COMPUTER PROGRAMMING
ENGM 1081
ASSIGNMENT 10
Due Date: Friday, December 4, 2015, 8:00 pm
For these questions you are not allowed to use the string functions in string.h
1. Write a p

Assignment 4
1
Department of Engineering Mathematics and Internetworking
COMPUTER PROGRAMMING
ENGM 1081
ASSIGNMENT 4
Due Date: Tuesday, October 13, 2015, 10:00 am
1. Write a program, derivative.c, to approximate the derivatives of ex , cos(x) and sin(x) a

Assignment 8
1
Department of Engineering Mathematics and Internetworking
COMPUTER PROGRAMMING
ENGM 1081
ASSIGNMENT 8
Due Date: Monday, November 9, 2015, 10:00am
1. The ow of toxic waste through a permeable media (e.g. soil) can be modeled using dierential

Assignment 6
1
Department of Engineering Mathematics and Internetworking
COMPUTER PROGRAMMING
ENGM 1081
ASSIGNMENT 6
Due Date: Monday, October 26, 2015, 10:00 am
1. Recall that an integer is called prime if its only divisors are 1 and the number itself. T

Assignment 1
1
Department of Engineering Mathematics and Internetworking
COMPUTER PROGRAMMING
ENGM 1081
ASSIGNMENT 1
Due Date: Monday, September 21, 2015, 10:00 am
1. Here is part of a program that begins by having the user input the x and y dimensions of

/* Question 1 source code */
/* File rectangle.c
Given the dimensions of a rectangle in metres, compute its area and
perimeter length.
*/
/include our librarys
#include <stdio.h>
#include <stdlib.h>
/start our program
int main (void)
cfw_
/declare your v

/* Question 1 source code */
#include<stdio.h>
#include<stdlib.h>
/something soes here
int is_prime(int m);
int main(void)
cfw_
int count= 0,n,m=1;
FILE*fout =fopen("primesout.txt","w");
printf("Enter the n: ");
scanf("0",&n);
printf("count prime

/* File: coins.c
Compute the value of coins entered by the user
Assignment: 1
Programmer: Chukwu Ugochukwu D.
Date: September 19, 2011
Question: 3
DalID: B00556842
Course: ENGM 1081
*/
#include <stdio.h>
int main(void)
cfw_
int h; /*
int q; /*
int d; /*
i

/* File: sumofsquares.c
Reads float values from a file and computes the sum of squares
of the values.
Assignment: 4
Programmer: Chukwu Ugochukwu D.
Date: October 7, 2011
Question: 4
DalID: B00556842
Course: ENGM 1081
*/
#include <stdio.h>
#include <stdlib

/* File: commasperiods.c
This program reads through a file and counts the number of commas
and periods as well as the total number of characters.
Assignment: 5
Programmer: Chukwu Ugochukwu D
Date: October 14, 2011
Question: 1
DalID: B00556842
Course: ENGM

/* File: averagearrayfunction.c
read a series of values from a file and uses a function to compute
the average
*/
#include <stdio.h>
#include <stdlib.h>
#define N 100
float average(float* x, int n);
int main(void)
cfw_
int n = 0; /* n is the number of arr

/* File quadraticdouble.c
Use the quadratic formula with float values
Assignment: 2
Programmer: Chukwu, Ugochukwu D.
Date: September 23, 2011
Question: 3
DalID: B00556842
Course: ENGM 1081
*/
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
int ma

/* File: profit.c
This program reads from a file giving the id, quantity, cost and price of
items sold and computes the total profit and the most profitable item.
*/
Assignment: 5
Programmer: Chukwu Ugochukwu D
Date: October 14, 2011
Question: 3
DalID: B0

#include <stdio.h>
#include <stdlib.h>
#include <math.h>
/* put your prototype here */
float newton(float x, float tolerance, float*ptr_root, int*ptr_iter);
int main(void)
cfw_
/* declare variables*/
FILE*outfile;
int iter;/*the number of itterations take

/* File: category.c
This program reads a peak windspeed for a tornado and reports
the tornado's category.
Assignment: 3
Programmer: Chukwu Ugochukwu
Date: September 30, 2011
Question: 2
DalID: B00556842
Course: ENGM 1081
*/
#include <stdio.h>
#include <st

/* File: smog.c
Program to compute a smog level from air parameters
Assignment: 3
Programmer: Chukwu Ugochukwu D.
Date: September 30, 2011
Question: 3
DalID: B00556842
Course: ENGM 1081
*/
#include <stdio.h>
int main(void)
cfw_
float ozone, carbon, nitrog

/* File threeint.c
Compute the sum and sum of squares of three integers entered by a user
Assignment: 1
Programmer: Chukwu Ugochukwu D.
Date: September 19, 2011
Question: 1
DalID: B00556842
Course: ENGM 1081
*/
#include <stdio.h>
int main(void)
cfw_
int a

/* File: approxpi.c
This program uses n terms of the the series:
pi*pi
= 12*(1 - 1/(2*2) + 1/(3*3) - 1/(4*4) + 1/(5*5) - . )
to approximate pi.
Note that term number i of the summation on the right above can
be written as:
term = pow(-1.0, i+1)/(i*i)
Note

/* Question 1 source file */
/* File: commasperiods.c
This program reads through a file and counts the number of commas
and periods as well as the total number of characters.
Assignment: 5 Question: 1
Programmer: Chukwu Ugochukwu D DalID: B0055684

Name:
ID:
1
DALHOUSIE UNIVERSITY
DEPARTMENT OF ENGINEERING MATHEMATICS
ENGM1081: COMPUTER PROGRAMMING
Test 4, November 18, 2011
This is a 50 minute closed book test. A summary page will be provided. Questions
have equal value. Write your answers, preferab