Preview

Cis 324 Midterm and Answers

Good Essays
Open Document
Open Document
2743 Words
Grammar
Grammar
Plagiarism
Plagiarism
Writing
Writing
Score
Score
Cis 324 Midterm and Answers
User | | Course | C++ Programming I | Test | Week 5 Midterm Exam | Started | 11/12/12 5:06 PM | Submitted | 11/13/12 10:28 PM | Status | Completed | Score | 64 out of 100 points | Time Elapsed | 2 hours, 0 minute out of 2 hours. | Instructions | The midterm exam consists of multiple choice questions. You will have 2 hours to complete it. Good Luck! |

Question 1
0 out of 2 points | | | Study the following code snippet: int greater_num(int num1, int num2)
{
if (num1 < 0 || num2 < 0)
{
cout << "Only POSITIVE Numbers!!!"; return 0;
}
else
{
if (num1 <= num2)
{
return num1;
}
else
{
return num2;
}
}
}
Which of the following describes a constraint on the use of this function?Answer | | | | | Selected Answer: | All of the above listed items. | Correct Answer: | The use of cout does not allow this function to be used for a graphics program. | | | | |
Question 2
2 out of 2 points | | | What is helpful when dealing with a complex set of instructions for developing the code?Answer | | | | | Selected Answer: | Performing a manual walkthrough on a piece of paper before the actual code is written. | Correct Answer: | Performing a manual walkthrough on a piece of paper before the actual code is written. | | | | |
Question 3
0 out of 2 points | | | Which of the following is true about functions?Answer | | | | | Selected Answer: | Functions can have multiple parameters and can return multiple return values. | Correct Answer: | Function can have multiple parameters and can return one return value. | | | | |
Question 4
0 out of 2 points | | | Which of the following must be provided when defining a function?Answer | | | | | Selected Answer: | A name for the function, a name for each parameter, and a name for the return value | Correct Answer: | A name for the function, a name and type for each parameter,

You May Also Find These Documents Helpful

  • Satisfactory Essays

    PT1420 Unit 8 Lab 8

    • 365 Words
    • 2 Pages

    Step 9: Explain what you think will be displayed to the screen in Step 8. (Reference:…

    • 365 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    NT2670 Lab1 2

    • 1472 Words
    • 7 Pages

    Each lab in this manual requires that you answer questions, save images of your screen, or perform other activities that you document in a worksheet named for the lab, such as lab1_2_worksheet. Your instructor will provide you with the worksheet files that you must complete for each lab. As you perform the exercises in each lab, open the appropriate worksheet file using WordPad, fill in the required information, and save the file to your…

    • 1472 Words
    • 7 Pages
    Good Essays
  • Satisfactory Essays

    Ctlls Unit 3 Essay

    • 342 Words
    • 2 Pages

    Another method that is used is setting a test on aspects of the work covered so far and this gives the opportunity for the learner to sit down reflect and put down on paper and produce a written…

    • 342 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    Compter Science

    • 819 Words
    • 4 Pages

    A ____ involves developing a clear, concise, and unambiguous statement of the exact problem the software is to solve.…

    • 819 Words
    • 4 Pages
    Good Essays
  • Powerful Essays

    differently from other types of writing. The results of the exercise or experiment are what are being…

    • 1647 Words
    • 7 Pages
    Powerful Essays
  • Powerful Essays

    |1.2 Demonstrate an understanding of the |Code listings show a variety of objects | |…

    • 2281 Words
    • 10 Pages
    Powerful Essays
  • Good Essays

    For example, if an individual is getting dressed, he/she can refer to a sequencing board in the bedroom and easily see the steps to getting dressed correctly.…

    • 427 Words
    • 2 Pages
    Good Essays
  • Satisfactory Essays

    The process of planning and developing a program can be tied together to simplify the whole process. The outcome…

    • 758 Words
    • 4 Pages
    Satisfactory Essays
  • Satisfactory Essays

    Prewriting is the longest step in the writing process, involving the overall topic of a project and all the research. This is where a team can contribute ideas and opinions, and a rough draft is…

    • 382 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    Additionally, the tutor sets an agenda before the student starts to read the paper by stating, “I am going to mark down what to come back to as you read”. After the student finishes reading, before the tutor expresses her opinions about the essay, she asks the student what she thinks about the work she just read. The tutor listens to the student’s response and then explains what and why she marked certain sentences or phases on the paper. Furthermore, when the tutor is making note of her corrections, she phrases her corrects in a suggestive way—“This could be changed, does this sounds better, I wonder if, I think we can scratch this”. After going through her notes, the tutor asks the student if she understands her corrections and after she answers, the tutor goes back to the corrections and asks the student, “how could we re-write this sentence”. Advising the student to “step back for a minute and think about a totally new sentence that does the same thing”, the tutor listens to the student’s new sentence structure. After verbally talking through the sentence, the tutor hands the student the pen to write down the new sentence—continuing scaffolding technique. In…

    • 564 Words
    • 3 Pages
    Good Essays
  • Satisfactory Essays

    and statements and confirm that they are free from errors before coding information. My friend’s…

    • 318 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    Psychology Study Guide

    • 946 Words
    • 4 Pages

    Scaffolding- process of adjusting instruction so that a beginner could better understand a problem or gain a mental skill…

    • 946 Words
    • 4 Pages
    Good Essays
  • Powerful Essays

    Writing Prompts

    • 3103 Words
    • 13 Pages

    Assignment: Prewriting 1 1. Choose one of the four prompts to brainstorm. 2. Write or type your choice on paper. 3. Follow the model for this assignment. (You may not use the prompt given in the model.) Remember brainstorming is different from writing. Take 15 minutes and do nothing but write or type. 4. Submit whatever you have when you finish. You may type into a document. You may scan what you write. 5. Label your work Prewriting 1a and put it into a folder named You will not submit this folder until you complete…

    • 3103 Words
    • 13 Pages
    Powerful Essays
  • Satisfactory Essays

    A method of paragraph or essay development by which a writer explains step by step how something is done or how to do something.…

    • 443 Words
    • 2 Pages
    Satisfactory Essays
  • Better Essays

    Prewriting is a method that allows me to generate and clarify ideas before approaching the composition. Before starting my paper, I like to brainstorm…

    • 1222 Words
    • 5 Pages
    Better Essays