CSCI 191

Réussis tes devoirs et examens dès maintenant avec Quizwiz!

What will the following code display?cout << "Monday";cout << "Tuesday";cout << "Wednesday";

. MondayTuesdayWednesday

Which of the following will allow the user to input the values 15 and 20 and have them stored in variables named base and height, respectively?

The correct answer is: cin >> base >> height;

Which statement is equivalent to the following?number += 1;

number = number + 1;

What is the value of number after the following statements execute? int number = 10; number += 5; number -= 2; number *= 3;

39

What is the value of average after the following code executes? double average;average = 1.0 + 2.0 + 3.0 / 3.0;

4.0

What is the value of result after the following statement executes?result = (3 * 5) % 4 + 24 / (15 - (7 - 4));

5

A variable definition tells the computer

the variable's name and the type of data it will hold


Ensembles d'études connexes

Ch. 6 - The Remaining Promulgated Forms

View Set

Chapter 28 Drugs for Angina Pectoris & MI

View Set

HESI Case Study - Psychiatric/Mental Health Practice Exam

View Set

Chapter 3 - Job-Order Costing: Cost Flows and External Reporting

View Set

Forensic Science - Ballistics Test

View Set

V for Vendetta quotes (hdeuropix timestamps)

View Set