[Skip Navigation] [CSUSB] / [CNS] / [CSE] / [R J Botting] >> [CSE201] >> [Lab01] >> index
[Index] [Schedule] [Syllabi] [Glossary] [Labs] [Projects] [Resources] [Grading] [Search ]
Notes: [01] [02] [03] [04] [05] [06] [07] [08] [09] [10] [11] [12] [13] [14] [15] [16] [17] [18] [19] [20]
Labs: [01] [02] [03] [04] [05] [06] [07] [08] [09] [10]
Wed May 16 14:24:06 PDT 2012

Contents


    Multifile programming

      Previous [ ../lab07/ ] Next [ ../lab09/ ]

      Goal

      1. To experiment with multifile programming -- Chapter 5, section 5.9
      2. To experiment with the Unix command line interfaces. Prepares for working remotely...
      Note -- if you don't use "gedit" or a graphic browser like "Firefox" you can do this lab remotely...

      Reference

      1. Makefiles [ ../15.html#Makefiles and make ]
      2. Multifile Programs [ ../15.html ] and Chapter 5, section 5.9.

      . . . . . . . . . ( end of section Reference) <<Contents | End>>

      Process

        Create and change to directory to cs201/lab08

         		cd cs201
         		mkdir lab08
         		cd lab08

        Download each of the following. [ plot.h ] [ plot.cpp ] [ graph.cpp ] [ makefile ] into your cs201/lab08

        Use make to compile and run the project

         	make

        Change the main program to plot a different function using vi

        In the lab you can use
         	gedit graph.cpp &
        or remotely (or if you are doing a CSE major) you should try out the 'vi' editor I use in class. First run this command
         	Q novice
        and then you can edit files like this
         	vi graph.cpp
        and tapping the letter 'q' will compile and run the program...

        Experiment 2 -- download and test the books prodtest code

        Download [ ../prodtest/ ]

        You can edit a makefile just like any other file.

        Add some recipes to this lab's makefile. Hint -- copy the examples already there and change the names of the files.

        Test the program and makefile.

        Get credit

        Work on project -- if time

        Take note of something you have learned

        Logout from the lab machine

      . . . . . . . . . ( end of section Process) <<Contents | End>>

    Abreviations

  1. Gnu::="Gnu's Not Unix", a long running open source project that supplies a very popular C++ compiler.
  2. TBA::="To Be Announced", something I have to do.
  3. TBD::="To Be Done", something you have to do.

End