COSC 1315

Programming Fundamentals

 Practice Text #107

The Sequence Structure

Revised: February 3, 2007
By Richard G. Baldwin

File Pfsg00107.htm
Practice Text Index


Welcome

The practice tests in this series were written specifically for the benefit of my students in COSC 1315, Fundamentals of Programming.  They consists of questions, answers, and explanations.  The questions are based on the material covered in my series of online lecture notes for the course.  Each practice test is keyed to a specific lecture.  This practice test is keyed to lecture #107 titled The Sequence Structure.

Questions



107-1.  Which of the following are common programming structures?

Answer and Explanation

107-2.  Which of the following common programming structures are included in the program in Listing 107-2?

Listing 107-2.
#include <iostream>
using namespace std;

int main(){//Global main function.
  cout << "Hello Viet Nam\n";
  cout << "Hello Iraq\n";
  cout << "Hello America\n";
  cout << "Hello World\n";
  return 0;
}//end main function

Answer and Explanation



Copyright 2007, Richard G. Baldwin.  Reproduction in whole or in part in any form or medium without express written permission from Richard Baldwin is prohibited.

About the author

Richard Baldwin is a college professor (at Austin Community College in Austin, TX) and private consultant whose primary focus is a combination of Java and XML. In addition to the many platform-independent benefits of Java applications, he believes that a combination of Java and XML will become the primary driving force in the delivery of structured information on the Web.

Richard has participated in numerous consulting projects involving Java, XML, or a combination of the two.  He frequently provides onsite Java and/or XML training at the high-tech companies located in and around Austin, Texas.  He is the author of Baldwin's Java Programming Tutorials, which has gained a worldwide following among experienced and aspiring Java programmers. He has also published articles on Java Programming in Java Pro magazine.

Richard holds an MSEE degree from Southern Methodist University and has many years of experience in the application of computer technology to real-world problems.

Baldwin@DickBaldwin.com


Answers and Explanations

Answer 2

A. Sequence

Back to Question 2

Explanation 2

Answer 1

E. All of the above

Back to Question 1

Explanation 1



Copyright 2007, Richard G. Baldwin.  Reproduction in whole or in part in any form or medium without express written permission from Richard Baldwin is prohibited.

About the author

Richard Baldwin is a college professor (at Austin Community College in Austin, TX) and private consultant whose primary focus is a combination of Java and XML. In addition to the many platform-independent benefits of Java applications, he believes that a combination of Java and XML will become the primary driving force in the delivery of structured information on the Web.

Richard has participated in numerous consulting projects involving Java, XML, or a combination of the two.  He frequently provides onsite Java and/or XML training at the high-tech companies located in and around Austin, Texas.  He is the author of Baldwin's Java Programming Tutorials, which has gained a worldwide following among experienced and aspiring Java programmers. He has also published articles on Java Programming in Java Pro magazine.

Richard holds an MSEE degree from Southern Methodist University and has many years of experience in the application of computer technology to real-world problems.

Baldwin@DickBaldwin.com

-end-