diff options
| -rw-r--r-- | BlankConsoleLab/BlankConsoleLab.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/BlankConsoleLab/BlankConsoleLab.cpp b/BlankConsoleLab/BlankConsoleLab.cpp index 11315de..8f7b61f 100644 --- a/BlankConsoleLab/BlankConsoleLab.cpp +++ b/BlankConsoleLab/BlankConsoleLab.cpp @@ -14,7 +14,7 @@ const float temp_min_F = -80, temp_max_F = 121, temp_min_C = -61, temp_max_C = 4 string input = ""; float temperature = 0, wind_speed = 0, wind_chill = 0;; -float Temp_Conversion(float temp) { +float Temp_Conversion(float& temp) { temp *= 1.8; temp += 32; return temp; @@ -34,6 +34,7 @@ int main() cout << "Please input 'F' for fahrenheit or 'C' for celsius: "; cin >> input; while (input != "F" && input != "C") { + cout << endl; cout << "That input is invalid." << endl; cout << "Make sure your input is capitalized." << endl; cout << "Please input 'F' for fahrenheit or 'C' for celsius: "; @@ -83,5 +84,5 @@ int main() //Calculate the Wind Chill wind_chill = Wind_Chill(temperature, wind_speed); - cout << "The wind chill is " << wind_chill << endl; + cout << "The wind chill is " << wind_chill<< "." << endl; }
\ No newline at end of file |