testanto - /* Name - Carlos email - cemoran@uh.edu ECE 3331...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
/***************************************************** Name - Carlos email - cemoran@uh.edu ECE 3331 Computer Project # 1 Semester Spring 2009 **************************************************** Purpose - To calculate and identify the area of triangles **************************************************** Data Files triangle.out - output file to which results will be written*/ #include <stdio.h> #include <math.h> #include <stdlib.h> #define PI 3.14159265 FILE *fin,*fout; main( ) { /*Setting the variables*/ int a, b, c, long_side, sid_1, sid_2, sid_3, trig; FILE *fin,*fout; fout = fopen("triangles2.out","w"); /********************* Performing task 1 ***********************************/ fprintf(fout,"******************Task 1****************** \n"); do { printf("Enter the value of a: "); scanf( "%d", &a); printf("Enter the value of b: "); scanf( "%d", &b); printf("Enter the value of c: "); scanf( "%d", &c); } while ( a < 0 || b < 0 || c < 0 || ( a + b ) < c + 1 || ( b + c ) < a +1 || ( a + c
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 10/26/2011 for the course ECE 3331 taught by Professor Staff during the Fall '08 term at University of Houston.

Page1 / 2

testanto - /* Name - Carlos email - cemoran@uh.edu ECE 3331...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online