Preview

Programming Style and Study Guide

Satisfactory Essays
Open Document
Open Document
289 Words
Grammar
Grammar
Plagiarism
Plagiarism
Writing
Writing
Score
Score
Programming Style and Study Guide
1

COS1511/102/3/2011

Introduction to programming 1 Tutorial letter 102 for COS1511 Solutions to exercises in the Study Guide

School of Computing

2 TUTORIAL MATTER

Up to now you should have received the material listed below. If not, please download it from myUnisa or osprey immediately (see below) and also contact the Department of Despatch. Study Guide DISK 2011 (with software ) Tutorial letters COSALLF/301/4/2011 General information concerning the School and study at Unisa COS1511/101/3/2011 Information about COS1511 Assignments COS1511/102/3/2011 This letter Please note the following • • For e-mail, use the module address namely cos1511@osprey.unisa.ac.za. Web addresses for downloading of tutorial matter myUnisa.ac.za osprey.unisa.ac.za (logon: MYDOWNLOAD, password SOC2011) You need AT LEAST 8 hours study time per week for this module.



Afrikaanssprekende studente: Studiemateriaal vir COS1511 is vanaf 2011 slegs in Engels beskikbaar. As enigiets onduidelik is, is u baie welkom om ons te kontak.

Your programs need not be identical to ours. It is, however, important that your programs yield the correct results (thus extensive testing is essential) and that you use good programming style as explained in the Study Guide. You should, for example,

3
• • • • • • • use meaningful names for variables, constants, functions, etc, indent your code correctly, include comments, declare constants where appropriate, avoid the use of global variables, use the correct types of functions as well as the correct types of parameters.

COS1511/102/3/2011

LESSON 1 Lesson 1, Exercise 1 We repeat the program here: #include using namespace std; int main( ) { cout deepDep; cout > shallowDep; SwimmingPool pool(len, wid, deepDep, shallowDep); // round up to get an integer value for volume

82

vol = pool.volume( );

You May Also Find These Documents Helpful

  • Satisfactory Essays

    IT210 Week 3

    • 756 Words
    • 4 Pages

    Resources: Review the example in Appendix E and the additional examples on pgs 80-83 of Prelude to Programming…

    • 756 Words
    • 4 Pages
    Satisfactory Essays
  • Good Essays

    This is our first individual assignment for Programming unit this semester. This assignment was given in December 2013, and submission date is on 10th February 2014.…

    • 1859 Words
    • 8 Pages
    Good Essays
  • Better Essays

    Venit, S., & Drake, E. (2011). Prelude to Programming Concepts and Design (5th ed.). Boston, MA: Addison-Wesley.…

    • 1800 Words
    • 6 Pages
    Better Essays
  • Satisfactory Essays

    CS 220 – Programming w/ Data Structures: You have missed one assignment and one quiz. Your instructor has extended your assignment due date to this Sunday, April 10. Your instructor has also let you to take your Quiz # 2 during his office hours during this week. Let me know if you need additional support to study for this quiz. Your grade to date in this class is 30.2/37 81.62% B.…

    • 354 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    Intro to programming

    • 534 Words
    • 3 Pages

    Design an algorithm that prompts the user to enter his or her height and stores the user’s input in a variable named height.…

    • 534 Words
    • 3 Pages
    Good Essays
  • Good Essays

    accessing web resources via the Internet. The purpose of this course is to build on students’…

    • 2426 Words
    • 13 Pages
    Good Essays
  • Satisfactory Essays

    WEB 435 Week 1 DQ 2

    • 393 Words
    • 2 Pages

    This work of WEB 435 Week 1 Discussion Question 2 comprises: A successful security policy requires the support of senior management. Should management also be involved in the development of a web security policy?…

    • 393 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    C Programming Worksheet2

    • 1009 Words
    • 8 Pages

    A program is required to read a customer’s name, a purchase amount and a tax code. The tax…

    • 1009 Words
    • 8 Pages
    Good Essays
  • Powerful Essays

    online gown rental system

    • 1313 Words
    • 6 Pages

    This Research Paper is lovingly dedicated to our respective Parents who have been our constant source of inspiration. They have given us the drive and discipline to tackle any task with enthusiasm and determination. Without their love and support this project would not have been made possible.…

    • 1313 Words
    • 6 Pages
    Powerful Essays
  • Better Essays

    C Programming

    • 1333 Words
    • 6 Pages

    In particular, you will write a menu-driven program that provides the user with the following options:…

    • 1333 Words
    • 6 Pages
    Better Essays
  • Good Essays

    Introductions to Prolog

    • 2151 Words
    • 9 Pages

    Created around 1972 by Alain Colmerauer with Philippe Roussel, based on Robert Kowalski’s procedural interpretation of Horn clauses. decidable subset: Datalog, a query and rule language for deductive databases its failure as a mainstream language traditionally due to the following: Prolog usage in Fifth Generation Computer Systems project (FGCS) FCGS was an initiative by Japan’s Ministry of International Trade and Industry, begun in 1982, to create a "fifth generation computer"…

    • 2151 Words
    • 9 Pages
    Good Essays
  • Satisfactory Essays

    Jongmense in Suid Afrika moet minder kieskeurig wees oor werk en eerder die ondervinding opdoen en sodoende n beter kans staan op n volgende geleentheid. Een van die belangrikste faktore wat daartoe kan bydra dat jongmense werk kry is sosiale netwerke soos familie, vriende en kennisse. Jongmense moet ook begin dink om hul eie besighede te begin. Daar moet veral gekyk word hoe die entrepreneurs in die informele sector omskep kan word in die formele sector besighede as werkskeppers.…

    • 288 Words
    • 2 Pages
    Satisfactory Essays
  • Satisfactory Essays

    Voorsitter. Jy kry Afrikaans in duisende boeke. Ons hoor gereeld van Afrikaanse dramas wat groot erkenning geniet, weet van verskillende Afrikaanse gedigte van wêreldklas en verneem telkens met belangstelling van ’n soveelste Afrikaanse roman wat in ’n ander taal vertaal is. Afrikaans laat hom dus wyd en syd geld. Dit staan immers nie terug vir enige ander taal as dit by seggenskrag kom nie. En tog: skaars ’n eeu of wat gelede was daar sekere Afrikaanssprekendes wat “die Taal” as ’n agterlike dialek van Nederlands beskou het. Dis ’n armsalige kombuistaaltjie. Hoe sou só ’n boerse flenter van ’n tongval met ’n uiters verskraalde grammatika en ’n tingerige woordeskat nou ooit gebore in staat wees om enige behoorlike uitdrukking aan edel gedagtes te gee? Maar dames en here, Afrikaans het soos ‘n soet kind al sy wortels geëet en vandag kan ons behoorlik kommunikeer.…

    • 1034 Words
    • 5 Pages
    Satisfactory Essays
  • Powerful Essays

    Draaiboek

    • 3720 Words
    • 15 Pages

    Verklaard een samenwerkingsverband aan te gaan op de datum van ondertekening. Dit samenwerkingsverband zal eindigen op 15 juni 2009. Ondergetekenden zijn afspraken overeengekomen, terug te vinden in dit draaiboek.…

    • 3720 Words
    • 15 Pages
    Powerful Essays
  • Powerful Essays

    Compiler

    • 32912 Words
    • 132 Pages

    Gordon S. Novak Jr. Department of Computer Sciences University of Texas at Austin novak@cs.utexas.edu http://www.cs.utexas.edu/users/novak…

    • 32912 Words
    • 132 Pages
    Powerful Essays