// file: $(ECE_1111)/labs/01/l01_03/myprog.cc // // revision history: // 20180724 (JP): initial version // // usage: // myprog.exe // // compilation: // g++ -o myprog.exe myprog.cc myfuncts_00.cc myfuncts_01.cc // // expected output: // nedc_000_[1]: myprog.exe // program name: myprog.exe // sum of 27 and 27.272699 is 54.272697 // // This is a simple C program where the code exists in multiple files. // This version was designed to demonstrate how to browse files in the // the Amazon AWS IDE. // // local include files // #include "myprog.h" // main: myprog // // This is a driver program that does some very simple things. // int main(int argc, const char** argv) { // declare a variable for status // int status = (int)0; // call the first function // long value_joe = 1; fprintf(stdout, "value = %d\n",value_joe); long i = set_value_long(&value_joe); fprintf(stdout, "value = %d\n",value_joe); float x = set_value_float(27.2727); float sum = compute_sum(i, x); // display the value // fprintf(stdout, "program name: %s\n", argv[0]); fprintf(stdout, " sum of %d and %f is %f\n", i, x, sum); // exit gracefully // return(status); }