0% found this document useful (0 votes)
118 views1 page

Original PDF

The document is an errata for a video on declaring and initializing arrays in C++ programming. It notes that the code example incorrectly declared the variable "days_in_year" as a double when it should have been an int since it was being used to declare the size of an array. The correct declaration of "days_in_year" as an int with a value of 365 is provided.

Uploaded by

Benjamin Mullen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
118 views1 page

Original PDF

The document is an errata for a video on declaring and initializing arrays in C++ programming. It notes that the code example incorrectly declared the variable "days_in_year" as a double when it should have been an int since it was being used to declare the size of an array. The correct declaration of "days_in_year" as an int with a value of 365 is provided.

Uploaded by

Benjamin Mullen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

Beginning C++ Programming

Errata

“Declaring and Initializing Arrays”

The code examples in this video show the declaration of days_in_year as follows:

const double days_in_year {365};

This is incorrect. The type of days_in_year should be int since it is being used to declare the size of
the array hi_temperatures.

The correct declaration should be:

const int days_in_year {365};

Best regards,
Frank Mitropoulos

1 Updated: 5/2018

You might also like